import snowflake from 'snowflake-sdk'; /** * Enable or disable verbose SQL logging to stderr. * Call this once at the start of a command when --verbose is set. */ export declare function setVerbose(enabled: boolean): void; export interface SnowflakeConnectionOverrides { account?: string; database?: string; password?: string; privateKeyPass?: string; privateKeyPath?: string; schema?: string; token?: string; username?: string; warehouse?: string; } /** * Create and connect a Snowflake connection. * Credentials and auth method are resolved from env vars; overrides take precedence. * * After connecting, applies session context (warehouse, database, schema) via * explicit USE statements — the connection-option equivalents are unreliable with * some auth methods, so we set them imperatively. */ export declare function connectToSnowflake(overrides?: SnowflakeConnectionOverrides): Promise; /** * Execute a SQL statement and return all result rows. */ export declare function executeQuery>(connection: snowflake.Connection, sqlText: string, binds?: snowflake.Binds): Promise; /** * Close a Snowflake connection. */ export declare function destroyConnection(connection: snowflake.Connection): Promise; /** * Parse a fully qualified table name (database.schema.table or schema.table or table). * Returns an object with the parts that were present. */ export declare function parseTableName(qualified: string): { database?: string; schema?: string; table: string; }; /** * Quote each part of a (possibly) dotted Snowflake identifier so that names * starting with digits or containing special characters are always valid. * Each segment is uppercased and wrapped in double-quotes. * * Examples: * "INTEL.1483.BLOCK_1" → "INTEL"."1483"."BLOCK_1" * "mydb.public.orders" → "MYDB"."PUBLIC"."ORDERS" */ export declare function quoteQualifiedName(qualified: string): string; export declare function convertXlsxToCsv(xlsxPath: string, sheet?: number | string, onRow?: (rowNumber: number) => void, onScan?: (sheetName: string, rowNumber: number) => void): Promise; /** * Convert every sheet in an XLSX file to individual CSV files in a single * streaming pass — much faster than calling convertXlsxToCsv once per sheet. * * Returns a Map from sheet name → csv file path. */ export declare function convertAllXlsxSheetsToCsv(xlsxPath: string, onRow?: (sheetName: string, rowNumber: number) => void): Promise>; /** * Return the list of sheet names in an XLSX workbook. * * Reads only xl/workbook.xml from the zip — no row data is loaded, making * this fast even for very large files. */ export declare function getXlsxSheetNames(xlsxPath: string): Promise;