Skip to content

Commit 10ba31d

Browse files
committed
[FIXUP] use command in unloadFromQuery
1 parent 19a74e9 commit 10ba31d

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

packages/cubejs-clickhouse-driver/src/ClickHouseDriver.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -701,7 +701,7 @@ export class ClickHouseDriver extends BaseDriver implements DriverInterface {
701701
const types = await this.queryColumnTypes(`(${sql})`, params);
702702
const exportPrefix = uuidv4();
703703

704-
await this.queryResponse(`
704+
const formattedQuery = sqlstring.format(`
705705
INSERT INTO FUNCTION
706706
s3(
707707
'https://${this.config.exportBucket.bucketName}.s3.${this.config.exportBucket.region}.amazonaws.com/${exportPrefix}/export.csv.gz',
@@ -712,6 +712,8 @@ export class ClickHouseDriver extends BaseDriver implements DriverInterface {
712712
${sql}
713713
`, params);
714714

715+
await this.command(formattedQuery);
716+
715717
const csvFile = await this.extractUnloadedFilesFromS3(
716718
{
717719
credentials: {

0 commit comments

Comments
 (0)