diff --git a/packages/cubejs-schema-compiler/src/adapter/BigqueryQuery.ts b/packages/cubejs-schema-compiler/src/adapter/BigqueryQuery.ts index c13e26d224f37..a65ce203648b6 100644 --- a/packages/cubejs-schema-compiler/src/adapter/BigqueryQuery.ts +++ b/packages/cubejs-schema-compiler/src/adapter/BigqueryQuery.ts @@ -142,10 +142,6 @@ export class BigqueryQuery extends BaseQuery { return new BigqueryFilter(this, filter); } - public dateSeriesSql(timeDimension: BaseTimeDimension) { - return `${timeDimension.dateSeriesAliasName()} AS (${this.seriesSql(timeDimension)})`; - } - public seriesSql(timeDimension: BaseTimeDimension) { const values = timeDimension.timeSeries().map( ([from, to]) => `select '${from}' f, '${to}' t` @@ -161,26 +157,6 @@ export class BigqueryQuery extends BaseQuery { return 6; } - public overTimeSeriesSelect(cumulativeMeasures, dateSeriesSql, baseQuery, dateJoinConditionSql, baseQueryAlias) { - const forSelect = this.overTimeSeriesForSelect(cumulativeMeasures); - const outerSeriesAlias = this.cubeAlias('outer_series'); - const outerBase = this.cubeAlias('outer_base'); - const timeDimensionAlias = this.timeDimensions.map(d => d.aliasName()).filter(d => !!d)[0]; - const aliasesForSelect = this.timeDimensions.map(d => d.dateSeriesSelectColumn(outerSeriesAlias)).concat( - this.dimensions.concat(cumulativeMeasures).map(s => s.aliasName()) - ).filter(c => !!c).join(', '); - const dateSeriesAlias = this.timeDimensions.map(d => `${d.dateSeriesAliasName()}`).filter(c => !!c)[0]; - return ` - WITH ${dateSeriesSql} SELECT ${aliasesForSelect} FROM - ${dateSeriesAlias} ${outerSeriesAlias} - LEFT JOIN ( - SELECT ${forSelect} FROM ${dateSeriesAlias} - INNER JOIN (${baseQuery}) AS ${baseQueryAlias} ON ${dateJoinConditionSql} - ${this.groupByClause()} - ) AS ${outerBase} ON ${outerSeriesAlias}.${this.escapeColumnName('date_from')} = ${outerBase}.${timeDimensionAlias} - `; - } - public subtractInterval(date, interval) { return `DATETIME_SUB(${date}, INTERVAL ${this.formatInterval(interval)[0]})`; } diff --git a/packages/cubejs-testing-drivers/fixtures/athena.json b/packages/cubejs-testing-drivers/fixtures/athena.json index a429d22fe442c..5d5fb228b9d72 100644 --- a/packages/cubejs-testing-drivers/fixtures/athena.json +++ b/packages/cubejs-testing-drivers/fixtures/athena.json @@ -150,10 +150,9 @@ "---------------------------------------", "querying BigECommerce: rolling window by 2 day without date range", "querying BigECommerce: rolling window by 2 month without date range", - "querying BigECommerce: rolling window YTD", "querying BigECommerce: rolling window YTD without date range", - "--------------------", + "--------------------", "week granularity is not supported for intervals", "--------------------", "querying BigECommerce: rolling window by 2 week", diff --git a/packages/cubejs-testing-drivers/fixtures/bigquery.json b/packages/cubejs-testing-drivers/fixtures/bigquery.json index 1f5edc1b40715..89aad2281c256 100644 --- a/packages/cubejs-testing-drivers/fixtures/bigquery.json +++ b/packages/cubejs-testing-drivers/fixtures/bigquery.json @@ -163,8 +163,8 @@ "querying BigECommerce: rolling window by 2 day without date range", "querying BigECommerce: rolling window by 2 month without date range", "querying BigECommerce: rolling window YTD without date range", - "--------------------", + "---------------------------------------", "SKIPPED SQL API (Need work)", "---------------------------------------", "SQL API: reuse params", diff --git a/packages/cubejs-testing-drivers/fixtures/clickhouse.json b/packages/cubejs-testing-drivers/fixtures/clickhouse.json index 89ca2cfcbd169..0838cd9323a0f 100644 --- a/packages/cubejs-testing-drivers/fixtures/clickhouse.json +++ b/packages/cubejs-testing-drivers/fixtures/clickhouse.json @@ -179,20 +179,25 @@ "querying BigECommerce: partitioned pre-agg", "querying BigECommerce: null sum", "querying BigECommerce: null boolean", + + "---------------------------------------", "Unsupported JOIN ON conditions. Unexpected 'big_e_commerce__order_date_month > subtractWeeks(date_to, 2)'", - "--------------------", + "---------------------------------------", "querying BigECommerce: rolling window by 2 day", "querying BigECommerce: rolling window by 2 week", "querying BigECommerce: rolling window by 2 month", + "querying BigECommerce: rolling window YTD (month)", + "querying BigECommerce: rolling window YTD (month + week)", + "querying BigECommerce: rolling window YTD (month + week + no gran)", + "querying BigECommerce: rolling window YTD (month + week + day)", + "querying BigECommerce: rolling window YTD (month + week + day + no gran)", "---------------------------------------", "Requires Tesseract. ", "---------------------------------------", "querying BigECommerce: rolling window by 2 day without date range", "querying BigECommerce: rolling window by 2 month without date range", - "querying BigECommerce: rolling window YTD", "querying BigECommerce: rolling window YTD without date range", - "--------------------", "---------------------------------------", "Custom Granularities ", @@ -210,6 +215,11 @@ "SQL API: Rollup over exprs", "SQL API: Rollup with aliases", "SQL API: Simple Rollup", - "SQL API: SQL push down push to cube quoted alias" + "SQL API: SQL push down push to cube quoted alias", + + "SKIPPED SQL API (due to inconsistency)", + "---------------------------------------", + "Below doesn't work probably due to strict type comparison in ClickHouse, but tests run across all DBs", + "SQL API: Rolling Window YTD (year + month + day + date_trunc IN)" ] } diff --git a/packages/cubejs-testing-drivers/fixtures/databricks-jdbc.json b/packages/cubejs-testing-drivers/fixtures/databricks-jdbc.json index 0dc7bd8106dfe..75c855a0a9063 100644 --- a/packages/cubejs-testing-drivers/fixtures/databricks-jdbc.json +++ b/packages/cubejs-testing-drivers/fixtures/databricks-jdbc.json @@ -215,9 +215,7 @@ "---------------------------------------", "querying BigECommerce: rolling window by 2 day without date range", "querying BigECommerce: rolling window by 2 month without date range", - "querying BigECommerce: rolling window YTD", "querying BigECommerce: rolling window YTD without date range", - "--------------------", "---------------------------------------", "Custom Granularities ", diff --git a/packages/cubejs-testing-drivers/fixtures/mssql.json b/packages/cubejs-testing-drivers/fixtures/mssql.json index 76d595fc385be..06a5ce5aea8b5 100644 --- a/packages/cubejs-testing-drivers/fixtures/mssql.json +++ b/packages/cubejs-testing-drivers/fixtures/mssql.json @@ -141,9 +141,8 @@ "---------------------------------------", "querying BigECommerce: rolling window by 2 day without date range", "querying BigECommerce: rolling window by 2 month without date range", - "querying BigECommerce: rolling window YTD", "querying BigECommerce: rolling window YTD without date range", - "--------------------", + "---------------------------------------", "SKIPPED SQL API (Need work)", "---------------------------------------", @@ -161,6 +160,12 @@ "SQL API: Extended nested Rollup over asterisk", "SQL API: ungrouped pre-agg", "SQL API: NULLS FIRST/LAST SQL push down", - "SQL API: SQL push down push to cube quoted alias" + "SQL API: SQL push down push to cube quoted alias", + + "---------------------------------------", + "Error during rewrite: Can't detect Cube query and it may be not supported yet.", + "---------------------------------------", + "SQL API: Rolling Window YTD (year + month + day + date_trunc equal)", + "SQL API: Rolling Window YTD (year + month + day + date_trunc IN)" ] } diff --git a/packages/cubejs-testing-drivers/fixtures/mysql.json b/packages/cubejs-testing-drivers/fixtures/mysql.json index 56167c862c4e8..68ff49f8d7c09 100644 --- a/packages/cubejs-testing-drivers/fixtures/mysql.json +++ b/packages/cubejs-testing-drivers/fixtures/mysql.json @@ -131,12 +131,12 @@ "querying BigECommerce: partitioned pre-agg", "querying BigECommerce: null sum", "querying BigECommerce: null boolean", + "---------------------------------------", "Requires Tesseract. ", "---------------------------------------", "querying BigECommerce: rolling window by 2 day without date range", "querying BigECommerce: rolling window by 2 month without date range", - "querying BigECommerce: rolling window YTD", "querying BigECommerce: rolling window YTD without date range", "---------------------------------------", @@ -157,6 +157,12 @@ "SQL API: Nested Rollup with aliases", "SQL API: Nested Rollup over asterisk", "SQL API: Extended nested Rollup over asterisk", - "SQL API: SQL push down push to cube quoted alias" + "SQL API: SQL push down push to cube quoted alias", + + "---------------------------------------", + "Error during rewrite: Can't detect Cube query and it may be not supported yet.", + "---------------------------------------", + "SQL API: Rolling Window YTD (year + month + day + date_trunc equal)", + "SQL API: Rolling Window YTD (year + month + day + date_trunc IN)" ] } diff --git a/packages/cubejs-testing-drivers/fixtures/postgres.json b/packages/cubejs-testing-drivers/fixtures/postgres.json index 94ad1dd94428e..533d18b7eb006 100644 --- a/packages/cubejs-testing-drivers/fixtures/postgres.json +++ b/packages/cubejs-testing-drivers/fixtures/postgres.json @@ -156,6 +156,7 @@ "querying Products: dimensions -- doesn't work wo ordering", "querying ECommerce: total quantity, avg discount, total sales, total profit by product + order + total -- rounding in athena", "querying ECommerce: total quantity, avg discount, total sales, total profit by product + order + total -- noisy test", + "---------------------------------------", "Requires Tesseract. ", "---------------------------------------", diff --git a/packages/cubejs-testing-drivers/fixtures/redshift.json b/packages/cubejs-testing-drivers/fixtures/redshift.json index 6075a40400a03..2181ec35dccc5 100644 --- a/packages/cubejs-testing-drivers/fixtures/redshift.json +++ b/packages/cubejs-testing-drivers/fixtures/redshift.json @@ -167,14 +167,14 @@ "querying Products: dimensions -- doesn't work wo ordering", "querying ECommerce: total quantity, avg discount, total sales, total profit by product + order + total -- rounding in athena", "querying ECommerce: total quantity, avg discount, total sales, total profit by product + order + total -- noisy test", + "---------------------------------------", "Requires Tesseract. ", "---------------------------------------", "querying BigECommerce: rolling window by 2 day without date range", "querying BigECommerce: rolling window by 2 month without date range", - "querying BigECommerce: rolling window YTD", "querying BigECommerce: rolling window YTD without date range", - + "---------------------------------------", "SKIPPED SQL API (Need work) ", "---------------------------------------", diff --git a/packages/cubejs-testing-drivers/fixtures/snowflake.json b/packages/cubejs-testing-drivers/fixtures/snowflake.json index 4b621ec1f2949..3458b34fe334c 100644 --- a/packages/cubejs-testing-drivers/fixtures/snowflake.json +++ b/packages/cubejs-testing-drivers/fixtures/snowflake.json @@ -232,12 +232,12 @@ "querying ECommerce: total quantity, avg discount, total sales, total profit by product + order + total -- noisy test", "querying BigECommerce: null sum", "querying BigECommerce: null boolean", + "---------------------------------------", "Requires Tesseract. ", "---------------------------------------", "querying BigECommerce: rolling window by 2 day without date range", "querying BigECommerce: rolling window by 2 month without date range", - "querying BigECommerce: rolling window YTD", "querying BigECommerce: rolling window YTD without date range" ] } diff --git a/packages/cubejs-testing-drivers/package.json b/packages/cubejs-testing-drivers/package.json index de9d4fc1fec22..44d6ba8c61c51 100644 --- a/packages/cubejs-testing-drivers/package.json +++ b/packages/cubejs-testing-drivers/package.json @@ -59,6 +59,7 @@ "redshift-core": "yarn test-driver -i dist/test/redshift-core.test.js", "redshift-full": "yarn test-driver -i dist/test/redshift-full.test.js", "redshift-export-bucket-s3-full": "yarn test-driver -i dist/test/redshift-export-bucket-s3-full.test.js", + "update-all-snapshots-local": "yarn run athena-export-bucket-s3-full --mode=local -u; yarn run bigquery-export-bucket-gcs-full --mode=local -u; yarn run clickhouse-full --mode=local -u; yarn run clickhouse-export-bucket-s3-full --mode=local -u; yarn run clickhouse-export-bucket-s3-prefix-full --mode=local -u; yarn run databricks-jdbc-export-bucket-azure-full --mode=local -u; yarn run databricks-jdbc-export-bucket-azure-prefix-full --mode=local -u; yarn run databricks-jdbc-export-bucket-gcs-full --mode=local -u; yarn run databricks-jdbc-export-bucket-gcs-prefix-full --mode=local -u; yarn run databricks-jdbc-export-bucket-s3-full --mode=local -u; yarn run databricks-jdbc-export-bucket-s3-prefix-full --mode=local -u; yarn run databricks-jdbc-full --mode=local -u; yarn run mssql-full --mode=local -u; yarn run mysql-full --mode=local -u; yarn run postgres-full --mode=local -u; yarn run redshift-export-bucket-s3-full --mode=local -u; yarn run redshift-full --mode=local -u; yarn run snowflake-encrypted-pk-full --mode=local -u; yarn run snowflake-export-bucket-azure-full --mode=local -u; yarn run snowflake-export-bucket-azure-prefix-full --mode=local -u; yarn run snowflake-export-bucket-azure-via-storage-integration-full --mode=local -u; yarn run snowflake-export-bucket-gcs-full --mode=local -u; yarn run snowflake-export-bucket-gcs-prefix-full --mode=local -u; yarn run snowflake-export-bucket-s3-full --mode=local -u; yarn run snowflake-full --mode=local -u", "tst": "clear && yarn tsc && yarn bigquery-core" }, "files": [ diff --git a/packages/cubejs-testing-drivers/src/tests/testQueries.ts b/packages/cubejs-testing-drivers/src/tests/testQueries.ts index 7b90cb0680cd2..878a6ab5dfa29 100644 --- a/packages/cubejs-testing-drivers/src/tests/testQueries.ts +++ b/packages/cubejs-testing-drivers/src/tests/testQueries.ts @@ -1579,7 +1579,7 @@ export function testQueries(type: string, { includeIncrementalSchemaSuite, exten expect(response.rawData()).toMatchSnapshot(); }); - execute('querying BigECommerce: rolling window YTD', async () => { + execute('querying BigECommerce: rolling window YTD (month)', async () => { const response = await client.load({ measures: [ 'BigECommerce.rollingCountYTD', @@ -1589,6 +1589,107 @@ export function testQueries(type: string, { includeIncrementalSchemaSuite, exten granularity: 'month', dateRange: ['2020-01-01', '2020-12-31'], }], + order: [ + ['BigECommerce.orderDate', 'asc'], + ], + }); + expect(response.rawData()).toMatchSnapshot(); + }); + + execute('querying BigECommerce: rolling window YTD (month + week)', async () => { + const response = await client.load({ + measures: [ + 'BigECommerce.rollingCountYTD', + ], + timeDimensions: [{ + dimension: 'BigECommerce.orderDate', + granularity: 'month', + dateRange: ['2020-01-01', '2020-12-31'], + }, { + dimension: 'BigECommerce.orderDate', + granularity: 'week', + dateRange: ['2020-01-01', '2020-12-31'], + }], + order: [ + ['BigECommerce.orderDate', 'asc'], + ], + }); + expect(response.rawData()).toMatchSnapshot(); + }); + + execute('querying BigECommerce: rolling window YTD (month + week + no gran)', async () => { + const response = await client.load({ + measures: [ + 'BigECommerce.rollingCountYTD', + ], + timeDimensions: [{ + dimension: 'BigECommerce.orderDate', + granularity: 'month', + dateRange: ['2020-01-01', '2020-12-31'], + }, { + dimension: 'BigECommerce.orderDate', + granularity: 'week', + dateRange: ['2020-01-01', '2020-12-31'], + }, { + dimension: 'BigECommerce.orderDate', + dateRange: ['2020-01-01', '2020-12-31'], + }], + order: [ + ['BigECommerce.orderDate', 'asc'], + ], + }); + expect(response.rawData()).toMatchSnapshot(); + }); + + execute('querying BigECommerce: rolling window YTD (month + week + day)', async () => { + const response = await client.load({ + measures: [ + 'BigECommerce.rollingCountYTD', + ], + timeDimensions: [{ + dimension: 'BigECommerce.orderDate', + granularity: 'month', + dateRange: ['2020-01-01', '2020-03-01'], + }, { + dimension: 'BigECommerce.orderDate', + granularity: 'week', + dateRange: ['2020-01-01', '2020-03-01'], + }, { + dimension: 'BigECommerce.orderDate', + granularity: 'day', + dateRange: ['2020-01-01', '2020-03-01'], + }], + order: [ + ['BigECommerce.orderDate', 'asc'], + ], + }); + expect(response.rawData()).toMatchSnapshot(); + }); + + execute('querying BigECommerce: rolling window YTD (month + week + day + no gran)', async () => { + const response = await client.load({ + measures: [ + 'BigECommerce.rollingCountYTD', + ], + timeDimensions: [{ + dimension: 'BigECommerce.orderDate', + granularity: 'month', + dateRange: ['2020-01-01', '2020-03-01'], + }, { + dimension: 'BigECommerce.orderDate', + granularity: 'week', + dateRange: ['2020-01-01', '2020-03-01'], + }, { + dimension: 'BigECommerce.orderDate', + granularity: 'day', + dateRange: ['2020-01-01', '2020-03-01'], + }, { + dimension: 'BigECommerce.orderDate', + dateRange: ['2020-01-01', '2020-03-01'], + }], + order: [ + ['BigECommerce.orderDate', 'asc'], + ], }); expect(response.rawData()).toMatchSnapshot(); }); @@ -1606,6 +1707,19 @@ export function testQueries(type: string, { includeIncrementalSchemaSuite, exten expect(response.rawData()).toMatchSnapshot(); }); + execute('querying BigECommerce: rolling window YTD without granularity', async () => { + const response = await client.load({ + measures: [ + 'BigECommerce.rollingCountYTD', + ], + timeDimensions: [{ + dimension: 'BigECommerce.orderDate', + dateRange: ['2020-01-01', '2020-03-01'], + }], + }); + expect(response.rawData()).toMatchSnapshot(); + }); + if (includeHLLSuite) { execute('querying BigECommerce: rolling count_distinct_approx window by 2 day', async () => { const response = await client.load({ @@ -2093,6 +2207,38 @@ from expect(res.rows).toMatchSnapshot(); }); + executePg('SQL API: Rolling Window YTD (year + month + day + date_trunc equal)', async (connection) => { + // It's important to use day granularity - it tests for ambiguous names + const res = await connection.query(` + SELECT + DATE_TRUNC('year', orderDate) AS "orderDateY", + DATE_TRUNC('month', orderDate) AS "orderDateM", + DATE_TRUNC('day', orderDate) AS "orderDateD", + MEASURE(rollingCountYTD) AS "rollingCountYTD" + FROM "BigECommerce" + WHERE DATE_TRUNC('year', orderDate) = CAST('2020-01-01' AS DATE) + GROUP BY 1, 2, 3 + ORDER BY 3 ASC NULLS FIRST; + `); + expect(res.rows).toMatchSnapshot(); + }); + + executePg('SQL API: Rolling Window YTD (year + month + day + date_trunc IN)', async (connection) => { + // It's important to use day granularity - it tests for ambiguous names + const res = await connection.query(` + SELECT + DATE_TRUNC('year', orderDate) AS "orderDateY", + DATE_TRUNC('month', orderDate) AS "orderDateM", + DATE_TRUNC('day', orderDate) AS "orderDateD", + MEASURE(rollingCountYTD) AS "rollingCountYTD" + FROM "BigECommerce" + WHERE DATE_TRUNC('year', orderDate) IN (CAST('2020-01-01' AS DATE)) + GROUP BY 1, 2, 3 + ORDER BY 3 ASC NULLS FIRST; + `); + expect(res.rows).toMatchSnapshot(); + }); + executePg('SQL API: SQL push down push to cube quoted alias', async (connection) => { const res = await connection.query(` SELECT diff --git a/packages/cubejs-testing-drivers/test/__snapshots__/athena-export-bucket-s3-full.test.ts.snap b/packages/cubejs-testing-drivers/test/__snapshots__/athena-export-bucket-s3-full.test.ts.snap index 0a5ec1590374a..66182cb4efd1f 100644 --- a/packages/cubejs-testing-drivers/test/__snapshots__/athena-export-bucket-s3-full.test.ts.snap +++ b/packages/cubejs-testing-drivers/test/__snapshots__/athena-export-bucket-s3-full.test.ts.snap @@ -22,6 +22,472 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/athena-driver SQL API: Rolling Window YTD (year + month + day + date_trunc IN) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + +exports[`Queries with the @cubejs-backend/athena-driver SQL API: Rolling Window YTD (year + month + day + date_trunc equal) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + exports[`Queries with the @cubejs-backend/athena-driver SQL API: Timeshift measure from cube 1`] = ` Array [ Object { @@ -2846,6 +3312,1097 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/athena-driver querying BigECommerce: rolling window YTD (month + week + day + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/athena-driver querying BigECommerce: rolling window YTD (month + week + day) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/athena-driver querying BigECommerce: rolling window YTD (month + week + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-03-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-04-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-06-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-09-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-10-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-11-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/athena-driver querying BigECommerce: rolling window YTD (month + week) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/athena-driver querying BigECommerce: rolling window YTD (month) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/athena-driver querying BigECommerce: rolling window YTD without granularity 1`] = ` +Array [ + Object { + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + exports[`Queries with the @cubejs-backend/athena-driver querying BigECommerce: rolling window by 2 day 1`] = ` Array [ Object { diff --git a/packages/cubejs-testing-drivers/test/__snapshots__/bigquery-export-bucket-gcs-full.test.ts.snap b/packages/cubejs-testing-drivers/test/__snapshots__/bigquery-export-bucket-gcs-full.test.ts.snap index 4ede85c023a74..d04f1e5455549 100644 --- a/packages/cubejs-testing-drivers/test/__snapshots__/bigquery-export-bucket-gcs-full.test.ts.snap +++ b/packages/cubejs-testing-drivers/test/__snapshots__/bigquery-export-bucket-gcs-full.test.ts.snap @@ -1620,6 +1620,472 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/bigquery-driver SQL API: Rolling Window YTD (year + month + day + date_trunc IN) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + +exports[`Queries with the @cubejs-backend/bigquery-driver SQL API: Rolling Window YTD (year + month + day + date_trunc equal) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + exports[`Queries with the @cubejs-backend/bigquery-driver SQL API: Rollup over exprs: rollup_over_exprs 1`] = ` Array [ Object { @@ -6311,47 +6777,47 @@ Array [ Object { "BigECommerce.orderDate": "2020-01-01T00:00:00.000", "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", - "BigECommerce.rollingCountApproxBy2Day": null, + "BigECommerce.rollingCountApproxBy2Day": 0, }, Object { "BigECommerce.orderDate": "2020-02-01T00:00:00.000", "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", - "BigECommerce.rollingCountApproxBy2Day": null, + "BigECommerce.rollingCountApproxBy2Day": 0, }, Object { "BigECommerce.orderDate": "2020-03-01T00:00:00.000", "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", - "BigECommerce.rollingCountApproxBy2Day": null, + "BigECommerce.rollingCountApproxBy2Day": 0, }, Object { "BigECommerce.orderDate": "2020-04-01T00:00:00.000", "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", - "BigECommerce.rollingCountApproxBy2Day": null, + "BigECommerce.rollingCountApproxBy2Day": 0, }, Object { "BigECommerce.orderDate": "2020-05-01T00:00:00.000", "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", - "BigECommerce.rollingCountApproxBy2Day": null, + "BigECommerce.rollingCountApproxBy2Day": 0, }, Object { "BigECommerce.orderDate": "2020-06-01T00:00:00.000", "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", - "BigECommerce.rollingCountApproxBy2Day": null, + "BigECommerce.rollingCountApproxBy2Day": 0, }, Object { "BigECommerce.orderDate": "2020-07-01T00:00:00.000", "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", - "BigECommerce.rollingCountApproxBy2Day": null, + "BigECommerce.rollingCountApproxBy2Day": 0, }, Object { "BigECommerce.orderDate": "2020-08-01T00:00:00.000", "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", - "BigECommerce.rollingCountApproxBy2Day": null, + "BigECommerce.rollingCountApproxBy2Day": 0, }, Object { "BigECommerce.orderDate": "2020-09-01T00:00:00.000", "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", - "BigECommerce.rollingCountApproxBy2Day": null, + "BigECommerce.rollingCountApproxBy2Day": 0, }, Object { "BigECommerce.orderDate": "2020-10-01T00:00:00.000", @@ -6361,12 +6827,12 @@ Array [ Object { "BigECommerce.orderDate": "2020-11-01T00:00:00.000", "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", - "BigECommerce.rollingCountApproxBy2Day": null, + "BigECommerce.rollingCountApproxBy2Day": 0, }, Object { "BigECommerce.orderDate": "2020-12-01T00:00:00.000", "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", - "BigECommerce.rollingCountApproxBy2Day": null, + "BigECommerce.rollingCountApproxBy2Day": 0, }, ] `; @@ -6411,7 +6877,7 @@ Array [ Object { "BigECommerce.orderDate": "2020-08-01T00:00:00.000", "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", - "BigECommerce.rollingCountApproxBy2Month": null, + "BigECommerce.rollingCountApproxBy2Month": 0, }, Object { "BigECommerce.orderDate": "2020-09-01T00:00:00.000", @@ -6456,7 +6922,7 @@ Array [ Object { "BigECommerce.orderDate": "2020-04-01T00:00:00.000", "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", - "BigECommerce.rollingCountApproxBy2Week": null, + "BigECommerce.rollingCountApproxBy2Week": 0, }, Object { "BigECommerce.orderDate": "2020-05-01T00:00:00.000", @@ -6471,12 +6937,12 @@ Array [ Object { "BigECommerce.orderDate": "2020-07-01T00:00:00.000", "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", - "BigECommerce.rollingCountApproxBy2Week": null, + "BigECommerce.rollingCountApproxBy2Week": 0, }, Object { "BigECommerce.orderDate": "2020-08-01T00:00:00.000", "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", - "BigECommerce.rollingCountApproxBy2Week": null, + "BigECommerce.rollingCountApproxBy2Week": 0, }, Object { "BigECommerce.orderDate": "2020-09-01T00:00:00.000", @@ -6501,122 +6967,1140 @@ Array [ ] `; -exports[`Queries with the @cubejs-backend/bigquery-driver querying BigECommerce: rolling window YTD 1`] = ` +exports[`Queries with the @cubejs-backend/bigquery-driver querying BigECommerce: rolling window YTD (month + week + day + no gran) 1`] = ` Array [ Object { - "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", - "BigECommerce.rollingCountYTD": 2, + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, }, Object { - "BigECommerce.orderDate": "2020-02-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", - "BigECommerce.rollingCountYTD": 3, + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, }, Object { - "BigECommerce.orderDate": "2020-03-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", - "BigECommerce.rollingCountYTD": 5, + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, }, Object { - "BigECommerce.orderDate": "2020-04-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", - "BigECommerce.rollingCountYTD": 6, + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, }, Object { - "BigECommerce.orderDate": "2020-05-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", - "BigECommerce.rollingCountYTD": 11, + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, }, Object { - "BigECommerce.orderDate": "2020-06-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", - "BigECommerce.rollingCountYTD": 18, + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, }, Object { - "BigECommerce.orderDate": "2020-07-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", - "BigECommerce.rollingCountYTD": 18, + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, }, Object { - "BigECommerce.orderDate": "2020-08-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", - "BigECommerce.rollingCountYTD": 18, + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, }, Object { - "BigECommerce.orderDate": "2020-09-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", - "BigECommerce.rollingCountYTD": 24, + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, }, Object { - "BigECommerce.orderDate": "2020-10-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", - "BigECommerce.rollingCountYTD": 28, + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, }, Object { - "BigECommerce.orderDate": "2020-11-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", - "BigECommerce.rollingCountYTD": 37, + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, }, Object { - "BigECommerce.orderDate": "2020-12-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", - "BigECommerce.rollingCountYTD": 44, + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, }, -] -`; - -exports[`Queries with the @cubejs-backend/bigquery-driver querying BigECommerce: rolling window YTD without date range 1`] = ` -Array [ Object { - "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", - "BigECommerce.rollingCountYTD": 2, + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, }, Object { - "BigECommerce.orderDate": "2020-02-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", - "BigECommerce.rollingCountYTD": 3, + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, }, Object { - "BigECommerce.orderDate": "2020-03-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", - "BigECommerce.rollingCountYTD": 5, + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, }, Object { - "BigECommerce.orderDate": "2020-04-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", - "BigECommerce.rollingCountYTD": 6, + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, }, Object { - "BigECommerce.orderDate": "2020-05-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", - "BigECommerce.rollingCountYTD": 11, + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, }, Object { - "BigECommerce.orderDate": "2020-06-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", - "BigECommerce.rollingCountYTD": 18, + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, }, Object { - "BigECommerce.orderDate": "2020-07-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", - "BigECommerce.rollingCountYTD": 18, + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, }, Object { - "BigECommerce.orderDate": "2020-08-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", - "BigECommerce.rollingCountYTD": 18, + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, }, Object { - "BigECommerce.orderDate": "2020-09-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", - "BigECommerce.rollingCountYTD": 24, + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, }, Object { - "BigECommerce.orderDate": "2020-10-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", - "BigECommerce.rollingCountYTD": 28, + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, +] +`; + +exports[`Queries with the @cubejs-backend/bigquery-driver querying BigECommerce: rolling window YTD (month + week + day) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, +] +`; + +exports[`Queries with the @cubejs-backend/bigquery-driver querying BigECommerce: rolling window YTD (month + week + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 5, + }, + Object { + "BigECommerce.orderDate": "2020-03-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 6, + }, + Object { + "BigECommerce.orderDate": "2020-04-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 11, + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 18, + }, + Object { + "BigECommerce.orderDate": "2020-06-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": 18, + }, + Object { + "BigECommerce.orderDate": "2020-07-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 18, + }, + Object { + "BigECommerce.orderDate": "2020-08-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": 24, + }, + Object { + "BigECommerce.orderDate": "2020-09-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": 28, + }, + Object { + "BigECommerce.orderDate": "2020-10-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": 37, + }, + Object { + "BigECommerce.orderDate": "2020-11-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 44, + }, +] +`; + +exports[`Queries with the @cubejs-backend/bigquery-driver querying BigECommerce: rolling window YTD (month + week) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 5, + }, + Object { + "BigECommerce.orderDate": "2020-03-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 6, + }, + Object { + "BigECommerce.orderDate": "2020-04-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 11, + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 18, + }, + Object { + "BigECommerce.orderDate": "2020-06-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": 18, + }, + Object { + "BigECommerce.orderDate": "2020-07-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 18, + }, + Object { + "BigECommerce.orderDate": "2020-08-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": 24, + }, + Object { + "BigECommerce.orderDate": "2020-09-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": 28, + }, + Object { + "BigECommerce.orderDate": "2020-10-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": 37, + }, + Object { + "BigECommerce.orderDate": "2020-11-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 44, + }, +] +`; + +exports[`Queries with the @cubejs-backend/bigquery-driver querying BigECommerce: rolling window YTD (month) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 5, + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 6, + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 11, + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 18, + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 18, + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 18, + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 24, + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 28, + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 37, + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 44, + }, +] +`; + +exports[`Queries with the @cubejs-backend/bigquery-driver querying BigECommerce: rolling window YTD without date range 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 5, + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 6, + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 11, + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 18, + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 18, + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 18, + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 24, + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 28, }, Object { "BigECommerce.orderDate": "2020-11-01T00:00:00.000", @@ -6631,6 +8115,14 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/bigquery-driver querying BigECommerce: rolling window YTD without granularity 1`] = ` +Array [ + Object { + "BigECommerce.rollingCountYTD": 44, + }, +] +`; + exports[`Queries with the @cubejs-backend/bigquery-driver querying BigECommerce: rolling window by 2 day 1`] = ` Array [ Object { diff --git a/packages/cubejs-testing-drivers/test/__snapshots__/clickhouse-export-bucket-s3-full.test.ts.snap b/packages/cubejs-testing-drivers/test/__snapshots__/clickhouse-export-bucket-s3-full.test.ts.snap index f1275b929ff23..d03b3dd2f234a 100644 --- a/packages/cubejs-testing-drivers/test/__snapshots__/clickhouse-export-bucket-s3-full.test.ts.snap +++ b/packages/cubejs-testing-drivers/test/__snapshots__/clickhouse-export-bucket-s3-full.test.ts.snap @@ -1620,6 +1620,239 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/clickhouse-driver export-bucket-s3 SQL API: Rolling Window YTD (year + month + day + date_trunc equal) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + exports[`Queries with the @cubejs-backend/clickhouse-driver export-bucket-s3 SQL API: Timeshift measure from cube 1`] = ` Array [ Object { @@ -4444,6 +4677,14 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/clickhouse-driver export-bucket-s3 querying BigECommerce: rolling window YTD without granularity 1`] = ` +Array [ + Object { + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + exports[`Queries with the @cubejs-backend/clickhouse-driver export-bucket-s3 querying BigECommerce: totalProfitYearAgo 1`] = `Array []`; exports[`Queries with the @cubejs-backend/clickhouse-driver export-bucket-s3 querying Customers: dimensions + limit 1`] = ` diff --git a/packages/cubejs-testing-drivers/test/__snapshots__/clickhouse-export-bucket-s3-prefix-full.test.ts.snap b/packages/cubejs-testing-drivers/test/__snapshots__/clickhouse-export-bucket-s3-prefix-full.test.ts.snap index 343055c8a4b3a..01349a561bf24 100644 --- a/packages/cubejs-testing-drivers/test/__snapshots__/clickhouse-export-bucket-s3-prefix-full.test.ts.snap +++ b/packages/cubejs-testing-drivers/test/__snapshots__/clickhouse-export-bucket-s3-prefix-full.test.ts.snap @@ -1620,6 +1620,239 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/clickhouse-driver export-bucket-s3-prefix SQL API: Rolling Window YTD (year + month + day + date_trunc equal) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + exports[`Queries with the @cubejs-backend/clickhouse-driver export-bucket-s3-prefix SQL API: Timeshift measure from cube 1`] = ` Array [ Object { @@ -4444,6 +4677,14 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/clickhouse-driver export-bucket-s3-prefix querying BigECommerce: rolling window YTD without granularity 1`] = ` +Array [ + Object { + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + exports[`Queries with the @cubejs-backend/clickhouse-driver export-bucket-s3-prefix querying BigECommerce: totalProfitYearAgo 1`] = `Array []`; exports[`Queries with the @cubejs-backend/clickhouse-driver export-bucket-s3-prefix querying Customers: dimensions + limit 1`] = ` diff --git a/packages/cubejs-testing-drivers/test/__snapshots__/clickhouse-full.test.ts.snap b/packages/cubejs-testing-drivers/test/__snapshots__/clickhouse-full.test.ts.snap index 2221fdc128706..5ad69963d3624 100644 --- a/packages/cubejs-testing-drivers/test/__snapshots__/clickhouse-full.test.ts.snap +++ b/packages/cubejs-testing-drivers/test/__snapshots__/clickhouse-full.test.ts.snap @@ -1620,6 +1620,239 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/clickhouse-driver SQL API: Rolling Window YTD (year + month + day + date_trunc equal) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + exports[`Queries with the @cubejs-backend/clickhouse-driver SQL API: Timeshift measure from cube 1`] = ` Array [ Object { @@ -4444,6 +4677,14 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/clickhouse-driver querying BigECommerce: rolling window YTD without granularity 1`] = ` +Array [ + Object { + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + exports[`Queries with the @cubejs-backend/clickhouse-driver querying BigECommerce: totalProfitYearAgo 1`] = `Array []`; exports[`Queries with the @cubejs-backend/clickhouse-driver querying Customers: dimensions + limit 1`] = ` diff --git a/packages/cubejs-testing-drivers/test/__snapshots__/databricks-jdbc-export-bucket-azure-full.test.ts.snap b/packages/cubejs-testing-drivers/test/__snapshots__/databricks-jdbc-export-bucket-azure-full.test.ts.snap index 05ff7008ee367..45dd13433e9b7 100644 --- a/packages/cubejs-testing-drivers/test/__snapshots__/databricks-jdbc-export-bucket-azure-full.test.ts.snap +++ b/packages/cubejs-testing-drivers/test/__snapshots__/databricks-jdbc-export-bucket-azure-full.test.ts.snap @@ -2614,6 +2614,472 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-azure SQL API: Rolling Window YTD (year + month + day + date_trunc IN) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-azure SQL API: Rolling Window YTD (year + month + day + date_trunc equal) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-azure SQL API: Rollup over exprs: rollup_over_exprs 1`] = ` Array [ Object { @@ -9317,6 +9783,1097 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-azure querying BigECommerce: rolling window YTD (month + week + day + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-azure querying BigECommerce: rolling window YTD (month + week + day) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-azure querying BigECommerce: rolling window YTD (month + week + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-azure querying BigECommerce: rolling window YTD (month + week) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-azure querying BigECommerce: rolling window YTD (month) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-azure querying BigECommerce: rolling window YTD without granularity 1`] = ` +Array [ + Object { + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-azure querying BigECommerce: rolling window by 2 day 1`] = ` Array [ Object { diff --git a/packages/cubejs-testing-drivers/test/__snapshots__/databricks-jdbc-export-bucket-azure-prefix-full.test.ts.snap b/packages/cubejs-testing-drivers/test/__snapshots__/databricks-jdbc-export-bucket-azure-prefix-full.test.ts.snap index 050e772bc9269..6a449ef7e1715 100644 --- a/packages/cubejs-testing-drivers/test/__snapshots__/databricks-jdbc-export-bucket-azure-prefix-full.test.ts.snap +++ b/packages/cubejs-testing-drivers/test/__snapshots__/databricks-jdbc-export-bucket-azure-prefix-full.test.ts.snap @@ -2614,6 +2614,472 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-azure-prefix SQL API: Rolling Window YTD (year + month + day + date_trunc IN) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-azure-prefix SQL API: Rolling Window YTD (year + month + day + date_trunc equal) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-azure-prefix SQL API: Rollup over exprs: rollup_over_exprs 1`] = ` Array [ Object { @@ -9122,6 +9588,1097 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-azure-prefix querying BigECommerce: rolling window YTD (month + week + day + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-azure-prefix querying BigECommerce: rolling window YTD (month + week + day) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-azure-prefix querying BigECommerce: rolling window YTD (month + week + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-azure-prefix querying BigECommerce: rolling window YTD (month + week) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-03-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-04-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-06-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-09-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-10-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-11-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-azure-prefix querying BigECommerce: rolling window YTD (month) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-azure-prefix querying BigECommerce: rolling window YTD without granularity 1`] = ` +Array [ + Object { + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-azure-prefix querying BigECommerce: rolling window by 2 day 1`] = ` Array [ Object { diff --git a/packages/cubejs-testing-drivers/test/__snapshots__/databricks-jdbc-export-bucket-gcs-full.test.ts.snap b/packages/cubejs-testing-drivers/test/__snapshots__/databricks-jdbc-export-bucket-gcs-full.test.ts.snap index 6d89ef63971ab..38940b393176c 100644 --- a/packages/cubejs-testing-drivers/test/__snapshots__/databricks-jdbc-export-bucket-gcs-full.test.ts.snap +++ b/packages/cubejs-testing-drivers/test/__snapshots__/databricks-jdbc-export-bucket-gcs-full.test.ts.snap @@ -2614,6 +2614,472 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-gcs SQL API: Rolling Window YTD (year + month + day + date_trunc IN) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-gcs SQL API: Rolling Window YTD (year + month + day + date_trunc equal) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-gcs SQL API: Rollup over exprs: rollup_over_exprs 1`] = ` Array [ Object { @@ -9317,6 +9783,1097 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-gcs querying BigECommerce: rolling window YTD (month + week + day + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-gcs querying BigECommerce: rolling window YTD (month + week + day) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-gcs querying BigECommerce: rolling window YTD (month + week + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-gcs querying BigECommerce: rolling window YTD (month + week) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-gcs querying BigECommerce: rolling window YTD (month) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-gcs querying BigECommerce: rolling window YTD without granularity 1`] = ` +Array [ + Object { + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-gcs querying BigECommerce: rolling window by 2 day 1`] = ` Array [ Object { diff --git a/packages/cubejs-testing-drivers/test/__snapshots__/databricks-jdbc-export-bucket-gcs-prefix-full.test.ts.snap b/packages/cubejs-testing-drivers/test/__snapshots__/databricks-jdbc-export-bucket-gcs-prefix-full.test.ts.snap index 28fbad50da184..5e6c6e2e47cbc 100644 --- a/packages/cubejs-testing-drivers/test/__snapshots__/databricks-jdbc-export-bucket-gcs-prefix-full.test.ts.snap +++ b/packages/cubejs-testing-drivers/test/__snapshots__/databricks-jdbc-export-bucket-gcs-prefix-full.test.ts.snap @@ -2614,6 +2614,472 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-gcs-prefix SQL API: Rolling Window YTD (year + month + day + date_trunc IN) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-gcs-prefix SQL API: Rolling Window YTD (year + month + day + date_trunc equal) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-gcs-prefix SQL API: Rollup over exprs: rollup_over_exprs 1`] = ` Array [ Object { @@ -9122,6 +9588,1097 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-gcs-prefix querying BigECommerce: rolling window YTD (month + week + day + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-gcs-prefix querying BigECommerce: rolling window YTD (month + week + day) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-gcs-prefix querying BigECommerce: rolling window YTD (month + week + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-03-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-04-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-06-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-09-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-10-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-11-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-gcs-prefix querying BigECommerce: rolling window YTD (month + week) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-gcs-prefix querying BigECommerce: rolling window YTD (month) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-gcs-prefix querying BigECommerce: rolling window YTD without granularity 1`] = ` +Array [ + Object { + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-gcs-prefix querying BigECommerce: rolling window by 2 day 1`] = ` Array [ Object { diff --git a/packages/cubejs-testing-drivers/test/__snapshots__/databricks-jdbc-export-bucket-s3-full.test.ts.snap b/packages/cubejs-testing-drivers/test/__snapshots__/databricks-jdbc-export-bucket-s3-full.test.ts.snap index f759420e12bc3..99645ada2970d 100644 --- a/packages/cubejs-testing-drivers/test/__snapshots__/databricks-jdbc-export-bucket-s3-full.test.ts.snap +++ b/packages/cubejs-testing-drivers/test/__snapshots__/databricks-jdbc-export-bucket-s3-full.test.ts.snap @@ -2614,6 +2614,472 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-s3 SQL API: Rolling Window YTD (year + month + day + date_trunc IN) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-s3 SQL API: Rolling Window YTD (year + month + day + date_trunc equal) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-s3 SQL API: Rollup over exprs: rollup_over_exprs 1`] = ` Array [ Object { @@ -9317,6 +9783,1097 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-s3 querying BigECommerce: rolling window YTD (month + week + day + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-s3 querying BigECommerce: rolling window YTD (month + week + day) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-s3 querying BigECommerce: rolling window YTD (month + week + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-03-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-04-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-06-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-09-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-10-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-11-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-s3 querying BigECommerce: rolling window YTD (month + week) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-03-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-04-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-06-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-09-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-10-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-11-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-s3 querying BigECommerce: rolling window YTD (month) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-s3 querying BigECommerce: rolling window YTD without granularity 1`] = ` +Array [ + Object { + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-s3 querying BigECommerce: rolling window by 2 day 1`] = ` Array [ Object { diff --git a/packages/cubejs-testing-drivers/test/__snapshots__/databricks-jdbc-export-bucket-s3-prefix-full.test.ts.snap b/packages/cubejs-testing-drivers/test/__snapshots__/databricks-jdbc-export-bucket-s3-prefix-full.test.ts.snap index 24c2cc871b852..dbef60f731ff3 100644 --- a/packages/cubejs-testing-drivers/test/__snapshots__/databricks-jdbc-export-bucket-s3-prefix-full.test.ts.snap +++ b/packages/cubejs-testing-drivers/test/__snapshots__/databricks-jdbc-export-bucket-s3-prefix-full.test.ts.snap @@ -2614,6 +2614,472 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-s3-prefix SQL API: Rolling Window YTD (year + month + day + date_trunc IN) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-s3-prefix SQL API: Rolling Window YTD (year + month + day + date_trunc equal) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-s3-prefix SQL API: Rollup over exprs: rollup_over_exprs 1`] = ` Array [ Object { @@ -9122,6 +9588,1097 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-s3-prefix querying BigECommerce: rolling window YTD (month + week + day + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-s3-prefix querying BigECommerce: rolling window YTD (month + week + day) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-s3-prefix querying BigECommerce: rolling window YTD (month + week + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-03-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-04-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-06-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-09-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-10-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-11-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-s3-prefix querying BigECommerce: rolling window YTD (month + week) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-03-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-04-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-06-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-09-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-10-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-11-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-s3-prefix querying BigECommerce: rolling window YTD (month) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-s3-prefix querying BigECommerce: rolling window YTD without granularity 1`] = ` +Array [ + Object { + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + exports[`Queries with the @cubejs-backend/databricks-jdbc-driver export-bucket-s3-prefix querying BigECommerce: rolling window by 2 day 1`] = ` Array [ Object { diff --git a/packages/cubejs-testing-drivers/test/__snapshots__/databricks-jdbc-full.test.ts.snap b/packages/cubejs-testing-drivers/test/__snapshots__/databricks-jdbc-full.test.ts.snap index a54b78fd4398d..05c023b84d584 100644 --- a/packages/cubejs-testing-drivers/test/__snapshots__/databricks-jdbc-full.test.ts.snap +++ b/packages/cubejs-testing-drivers/test/__snapshots__/databricks-jdbc-full.test.ts.snap @@ -2614,6 +2614,472 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver SQL API: Rolling Window YTD (year + month + day + date_trunc IN) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver SQL API: Rolling Window YTD (year + month + day + date_trunc equal) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + exports[`Queries with the @cubejs-backend/databricks-jdbc-driver SQL API: Rollup over exprs: rollup_over_exprs 1`] = ` Array [ Object { @@ -9317,6 +9783,1097 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver querying BigECommerce: rolling window YTD (month + week + day + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver querying BigECommerce: rolling window YTD (month + week + day) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver querying BigECommerce: rolling window YTD (month + week + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver querying BigECommerce: rolling window YTD (month + week) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-03-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-04-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-06-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-09-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-10-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-11-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver querying BigECommerce: rolling window YTD (month) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/databricks-jdbc-driver querying BigECommerce: rolling window YTD without granularity 1`] = ` +Array [ + Object { + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + exports[`Queries with the @cubejs-backend/databricks-jdbc-driver querying BigECommerce: rolling window by 2 day 1`] = ` Array [ Object { diff --git a/packages/cubejs-testing-drivers/test/__snapshots__/mssql-full.test.ts.snap b/packages/cubejs-testing-drivers/test/__snapshots__/mssql-full.test.ts.snap index 8d9558a3d6c72..81aaf2d7de0c2 100644 --- a/packages/cubejs-testing-drivers/test/__snapshots__/mssql-full.test.ts.snap +++ b/packages/cubejs-testing-drivers/test/__snapshots__/mssql-full.test.ts.snap @@ -2864,6 +2864,1097 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/mssql-driver querying BigECommerce: rolling window YTD (month + week + day + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-02T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-04T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-05T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-07T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-08T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-09T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-11T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-12T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-14T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-15T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-16T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-18T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-19T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-21T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-22T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-23T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-25T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-02T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-04T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-05T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-07T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-08T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-09T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-11T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-12T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-14T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-15T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-16T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-18T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-19T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-21T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-22T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-23T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-25T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, +] +`; + +exports[`Queries with the @cubejs-backend/mssql-driver querying BigECommerce: rolling window YTD (month + week + day) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-02T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-04T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-05T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-07T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-08T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-09T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-11T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-12T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-14T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-15T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-16T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-18T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-19T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-21T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-22T00:00:00.000", + "BigECommerce.rollingCountYTD": "10000", + }, + Object { + "BigECommerce.orderDate": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-23T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-25T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-02T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-04T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-05T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-07T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-08T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-09T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-11T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-12T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-14T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-15T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-16T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-18T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-19T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-21T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-22T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-23T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-25T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, +] +`; + +exports[`Queries with the @cubejs-backend/mssql-driver querying BigECommerce: rolling window YTD (month + week + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "50000", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "60000", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-05-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "110000", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "180000", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "180000", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "180000", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "240000", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "280000", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "370000", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-12-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "440000", + }, +] +`; + +exports[`Queries with the @cubejs-backend/mssql-driver querying BigECommerce: rolling window YTD (month + week) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "50000", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "60000", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-05-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "110000", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "180000", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "180000", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "180000", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "240000", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "280000", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "370000", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-12-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "440000", + }, +] +`; + +exports[`Queries with the @cubejs-backend/mssql-driver querying BigECommerce: rolling window YTD (month) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "20000", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "30000", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "50000", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "60000", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "110000", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "180000", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "180000", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "180000", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "240000", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "280000", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "370000", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "440000", + }, +] +`; + +exports[`Queries with the @cubejs-backend/mssql-driver querying BigECommerce: rolling window YTD without granularity 1`] = ` +Array [ + Object { + "BigECommerce.rollingCountYTD": "440000", + }, +] +`; + exports[`Queries with the @cubejs-backend/mssql-driver querying BigECommerce: rolling window by 2 day 1`] = ` Array [ Object { diff --git a/packages/cubejs-testing-drivers/test/__snapshots__/mysql-full.test.ts.snap b/packages/cubejs-testing-drivers/test/__snapshots__/mysql-full.test.ts.snap index 052a00c0734b3..c3bf049093f60 100644 --- a/packages/cubejs-testing-drivers/test/__snapshots__/mysql-full.test.ts.snap +++ b/packages/cubejs-testing-drivers/test/__snapshots__/mysql-full.test.ts.snap @@ -2829,6 +2829,1097 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/mysql-driver querying BigECommerce: rolling window YTD (month + week + day + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, +] +`; + +exports[`Queries with the @cubejs-backend/mysql-driver querying BigECommerce: rolling window YTD (month + week + day) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": 1, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, +] +`; + +exports[`Queries with the @cubejs-backend/mysql-driver querying BigECommerce: rolling window YTD (month + week + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 5, + }, + Object { + "BigECommerce.orderDate": "2020-03-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 6, + }, + Object { + "BigECommerce.orderDate": "2020-04-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 11, + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 18, + }, + Object { + "BigECommerce.orderDate": "2020-06-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": 18, + }, + Object { + "BigECommerce.orderDate": "2020-07-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 18, + }, + Object { + "BigECommerce.orderDate": "2020-08-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": 24, + }, + Object { + "BigECommerce.orderDate": "2020-09-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": 28, + }, + Object { + "BigECommerce.orderDate": "2020-10-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": 37, + }, + Object { + "BigECommerce.orderDate": "2020-11-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 44, + }, +] +`; + +exports[`Queries with the @cubejs-backend/mysql-driver querying BigECommerce: rolling window YTD (month + week) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": 5, + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 6, + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 11, + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 18, + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": 18, + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": 18, + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": 24, + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": 28, + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": 37, + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": 44, + }, +] +`; + +exports[`Queries with the @cubejs-backend/mysql-driver querying BigECommerce: rolling window YTD (month) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 2, + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 3, + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 5, + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 6, + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 11, + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 18, + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 18, + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 18, + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 24, + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 28, + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 37, + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.rollingCountYTD": 44, + }, +] +`; + +exports[`Queries with the @cubejs-backend/mysql-driver querying BigECommerce: rolling window YTD without granularity 1`] = ` +Array [ + Object { + "BigECommerce.rollingCountYTD": 44, + }, +] +`; + exports[`Queries with the @cubejs-backend/mysql-driver querying BigECommerce: rolling window by 2 day 1`] = ` Array [ Object { diff --git a/packages/cubejs-testing-drivers/test/__snapshots__/postgres-full.test.ts.snap b/packages/cubejs-testing-drivers/test/__snapshots__/postgres-full.test.ts.snap index c432883af4846..27319f9523c98 100644 --- a/packages/cubejs-testing-drivers/test/__snapshots__/postgres-full.test.ts.snap +++ b/packages/cubejs-testing-drivers/test/__snapshots__/postgres-full.test.ts.snap @@ -4670,6 +4670,472 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/postgres-driver SQL API: Rolling Window YTD (year + month + day + date_trunc IN) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + +exports[`Queries with the @cubejs-backend/postgres-driver SQL API: Rolling Window YTD (year + month + day + date_trunc equal) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + exports[`Queries with the @cubejs-backend/postgres-driver SQL API: Rollup over exprs: rollup_over_exprs 1`] = ` Array [ Object { @@ -11373,127 +11839,1145 @@ Array [ ] `; -exports[`Queries with the @cubejs-backend/postgres-driver querying BigECommerce: rolling window YTD 1`] = ` +exports[`Queries with the @cubejs-backend/postgres-driver querying BigECommerce: rolling window YTD (month + week + day + no gran) 1`] = ` Array [ Object { - "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", - "BigECommerce.rollingCountYTD": "2", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", }, Object { - "BigECommerce.orderDate": "2020-02-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", - "BigECommerce.rollingCountYTD": "3", + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", }, Object { - "BigECommerce.orderDate": "2020-03-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", - "BigECommerce.rollingCountYTD": "5", + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", }, Object { - "BigECommerce.orderDate": "2020-04-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", - "BigECommerce.rollingCountYTD": "6", + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", }, Object { - "BigECommerce.orderDate": "2020-05-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", - "BigECommerce.rollingCountYTD": "11", + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", }, Object { - "BigECommerce.orderDate": "2020-06-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", - "BigECommerce.rollingCountYTD": "18", + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", }, Object { - "BigECommerce.orderDate": "2020-07-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", - "BigECommerce.rollingCountYTD": "18", + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", }, Object { - "BigECommerce.orderDate": "2020-08-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", - "BigECommerce.rollingCountYTD": "18", + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", }, Object { - "BigECommerce.orderDate": "2020-09-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", - "BigECommerce.rollingCountYTD": "24", + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", }, Object { - "BigECommerce.orderDate": "2020-10-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", - "BigECommerce.rollingCountYTD": "28", + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", }, Object { - "BigECommerce.orderDate": "2020-11-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", - "BigECommerce.rollingCountYTD": "37", + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", }, Object { - "BigECommerce.orderDate": "2020-12-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", - "BigECommerce.rollingCountYTD": "44", + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", }, -] -`; - -exports[`Queries with the @cubejs-backend/postgres-driver querying BigECommerce: rolling window YTD without date range 1`] = ` -Array [ Object { - "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", - "BigECommerce.rollingCountYTD": "2", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", }, Object { - "BigECommerce.orderDate": "2020-02-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", - "BigECommerce.rollingCountYTD": "3", + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", }, Object { - "BigECommerce.orderDate": "2020-03-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", - "BigECommerce.rollingCountYTD": "5", + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", }, Object { - "BigECommerce.orderDate": "2020-04-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", - "BigECommerce.rollingCountYTD": "6", + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", }, Object { - "BigECommerce.orderDate": "2020-05-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", - "BigECommerce.rollingCountYTD": "11", + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", }, Object { - "BigECommerce.orderDate": "2020-06-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", - "BigECommerce.rollingCountYTD": "18", + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", }, Object { - "BigECommerce.orderDate": "2020-07-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", - "BigECommerce.rollingCountYTD": "18", + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", }, Object { - "BigECommerce.orderDate": "2020-08-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", - "BigECommerce.rollingCountYTD": "18", + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", }, Object { - "BigECommerce.orderDate": "2020-09-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", - "BigECommerce.rollingCountYTD": "24", + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", }, Object { - "BigECommerce.orderDate": "2020-10-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", - "BigECommerce.rollingCountYTD": "28", + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", }, Object { - "BigECommerce.orderDate": "2020-11-01T00:00:00.000", - "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", - "BigECommerce.rollingCountYTD": "37", + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/postgres-driver querying BigECommerce: rolling window YTD (month + week + day) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/postgres-driver querying BigECommerce: rolling window YTD (month + week + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-03-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-04-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-06-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-09-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-10-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-11-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/postgres-driver querying BigECommerce: rolling window YTD (month + week) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-03-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-04-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-06-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-09-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-10-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-11-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/postgres-driver querying BigECommerce: rolling window YTD (month) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/postgres-driver querying BigECommerce: rolling window YTD without date range 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", }, Object { "BigECommerce.orderDate": "2020-12-01T00:00:00.000", @@ -11503,6 +12987,14 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/postgres-driver querying BigECommerce: rolling window YTD without granularity 1`] = ` +Array [ + Object { + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + exports[`Queries with the @cubejs-backend/postgres-driver querying BigECommerce: rolling window by 2 day 1`] = ` Array [ Object { diff --git a/packages/cubejs-testing-drivers/test/__snapshots__/redshift-export-bucket-s3-full.test.ts.snap b/packages/cubejs-testing-drivers/test/__snapshots__/redshift-export-bucket-s3-full.test.ts.snap index e463bcb330a7d..5bd13ee063dfb 100644 --- a/packages/cubejs-testing-drivers/test/__snapshots__/redshift-export-bucket-s3-full.test.ts.snap +++ b/packages/cubejs-testing-drivers/test/__snapshots__/redshift-export-bucket-s3-full.test.ts.snap @@ -4670,6 +4670,472 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/redshift-driver export-bucket-s3 SQL API: Rolling Window YTD (year + month + day + date_trunc IN) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + +exports[`Queries with the @cubejs-backend/redshift-driver export-bucket-s3 SQL API: Rolling Window YTD (year + month + day + date_trunc equal) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + exports[`Queries with the @cubejs-backend/redshift-driver export-bucket-s3 SQL API: Rollup over exprs: rollup_over_exprs 1`] = ` Array [ Object { @@ -11170,6 +11636,1097 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/redshift-driver export-bucket-s3 querying BigECommerce: rolling window YTD (month + week + day + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/redshift-driver export-bucket-s3 querying BigECommerce: rolling window YTD (month + week + day) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/redshift-driver export-bucket-s3 querying BigECommerce: rolling window YTD (month + week + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-03-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-04-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-06-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-09-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-10-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-11-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/redshift-driver export-bucket-s3 querying BigECommerce: rolling window YTD (month + week) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/redshift-driver export-bucket-s3 querying BigECommerce: rolling window YTD (month) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/redshift-driver export-bucket-s3 querying BigECommerce: rolling window YTD without granularity 1`] = ` +Array [ + Object { + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + exports[`Queries with the @cubejs-backend/redshift-driver export-bucket-s3 querying BigECommerce: rolling window by 2 day 1`] = ` Array [ Object { diff --git a/packages/cubejs-testing-drivers/test/__snapshots__/redshift-full.test.ts.snap b/packages/cubejs-testing-drivers/test/__snapshots__/redshift-full.test.ts.snap index feb96785b15b6..b888b234b51f9 100644 --- a/packages/cubejs-testing-drivers/test/__snapshots__/redshift-full.test.ts.snap +++ b/packages/cubejs-testing-drivers/test/__snapshots__/redshift-full.test.ts.snap @@ -4670,6 +4670,472 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/redshift-driver SQL API: Rolling Window YTD (year + month + day + date_trunc IN) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + +exports[`Queries with the @cubejs-backend/redshift-driver SQL API: Rolling Window YTD (year + month + day + date_trunc equal) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + exports[`Queries with the @cubejs-backend/redshift-driver SQL API: Rollup over exprs: rollup_over_exprs 1`] = ` Array [ Object { @@ -11170,6 +11636,1097 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/redshift-driver querying BigECommerce: rolling window YTD (month + week + day + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/redshift-driver querying BigECommerce: rolling window YTD (month + week + day) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/redshift-driver querying BigECommerce: rolling window YTD (month + week + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-03-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-04-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-06-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-09-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-10-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-11-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/redshift-driver querying BigECommerce: rolling window YTD (month + week) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/redshift-driver querying BigECommerce: rolling window YTD (month) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/redshift-driver querying BigECommerce: rolling window YTD without granularity 1`] = ` +Array [ + Object { + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + exports[`Queries with the @cubejs-backend/redshift-driver querying BigECommerce: rolling window by 2 day 1`] = ` Array [ Object { diff --git a/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-encrypted-pk-full.test.ts.snap b/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-encrypted-pk-full.test.ts.snap index fc4da49bdd500..dde1e7aba30c9 100644 --- a/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-encrypted-pk-full.test.ts.snap +++ b/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-encrypted-pk-full.test.ts.snap @@ -8126,231 +8126,6 @@ Array [ ] `; -exports[`Queries with the @cubejs-backend/snowflake-driver encrypted-pk SQL API: metabase count cast to float32 from push down: metabase_count_cast_to_float32_from_push_down 1`] = ` -Array [ - Object { - "a0": 41, - }, -] -`; - -exports[`Queries with the @cubejs-backend/snowflake-driver encrypted-pk SQL API: post-aggregate percentage of total: post_aggregate_percentage_of_total 1`] = ` -Array [ - Object { - "SUM(BigECommerce.percentageOfTotalForStatus)": 100, - }, -] -`; - -exports[`Queries with the @cubejs-backend/snowflake-driver encrypted-pk SQL API: powerbi min max push down: powerbi_min_max_push_down 1`] = ` -Array [ - Object { - "a0": 2020-12-25T00:00:00.000Z, - "a1": 2020-01-01T00:00:00.000Z, - }, -] -`; - -exports[`Queries with the @cubejs-backend/snowflake-driver encrypted-pk SQL API: powerbi min max ungrouped flag: powerbi_min_max_ungrouped_flag 1`] = ` -Array [ - Object { - "a0": "39", - "a1": 3.76, - "a2": 2399.96, - }, -] -`; - -exports[`Queries with the @cubejs-backend/snowflake-driver encrypted-pk SQL API: reuse params: reuse_params 1`] = ` -Array [ - Object { - "c0": 2020-01-01T00:00:00.000Z, - "m0": 17372, - }, -] -`; - -exports[`Queries with the @cubejs-backend/snowflake-driver encrypted-pk SQL API: ungrouped pre-agg: ungrouped_pre_agg 1`] = ` -Array [ - Object { - "productName": "Canon PC1080F Personal Copier", - "totalSales": 2399.96, - }, - Object { - "productName": "Logitech di_Novo Edge Keyboard", - "totalSales": 2249.91, - }, - Object { - "productName": "Global Adaptabilites Bookcase, Cherry/Storm Gray Finish", - "totalSales": 2154.9, - }, - Object { - "productName": "Google Nexus 5", - "totalSales": 1979.89, - }, - Object { - "productName": "Global Adaptabilites Bookcase, Cherry/Storm Gray Finish", - "totalSales": 1292.94, - }, - Object { - "productName": "Canon PC1080F Personal Copier", - "totalSales": 1199.98, - }, - Object { - "productName": "Hewlett Packard 610 Color Digital Copier / Printer", - "totalSales": 899.982, - }, - Object { - "productName": "Okidata C610n Printer", - "totalSales": 649, - }, - Object { - "productName": "Lexmark 20R1285 X6650 Wireless All-in-One Printer", - "totalSales": 600, - }, - Object { - "productName": "Google Nexus 6", - "totalSales": 539.97, - }, - Object { - "productName": "Google Nexus 7", - "totalSales": 539.97, - }, - Object { - "productName": "Harbour Creations 67200 Series Stacking Chairs", - "totalSales": 498.26, - }, - Object { - "productName": "DMI Eclipse Executive Suite Bookcases", - "totalSales": 400.784, - }, - Object { - "productName": "HTC One", - "totalSales": 239.976, - }, - Object { - "productName": "Iceberg Nesting Folding Chair, 19w x 6d x 43h", - "totalSales": 232.88, - }, - Object { - "productName": "Balt Solid Wood Rectangular Table", - "totalSales": 210.98, - }, - Object { - "productName": "Tyvek Side-Opening Peel & Seel Expanding Envelopes", - "totalSales": 180.96, - }, - Object { - "productName": "Panasonic KP-380BK Classic Electric Pencil Sharpener", - "totalSales": 179.9, - }, - Object { - "productName": "Harbour Creations 67200 Series Stacking Chairs", - "totalSales": 128.124, - }, - Object { - "productName": "Harbour Creations 67200 Series Stacking Chairs", - "totalSales": 113.888, - }, - Object { - "productName": "Panasonic KP-380BK Classic Electric Pencil Sharpener", - "totalSales": 86.352, - }, - Object { - "productName": "Kingston Digital DataTraveler 16GB USB 2.2", - "totalSales": 71.6, - }, - Object { - "productName": "Linden 10 Round Wall Clock, Black", - "totalSales": 48.896, - }, - Object { - "productName": "Vinyl Coated Wire Paper Clips in Organizer Box, 800/Box", - "totalSales": 45.92, - }, - Object { - "productName": "Vinyl Coated Wire Paper Clips in Organizer Box, 800/Box", - "totalSales": 45.92, - }, - Object { - "productName": "Kingston Digital DataTraveler 16GB USB 2.0", - "totalSales": 44.75, - }, - Object { - "productName": "Kingston Digital DataTraveler 16GB USB 2.1", - "totalSales": 44.75, - }, - Object { - "productName": "Recycled Eldon Regeneration Jumbo File", - "totalSales": 39.296, - }, - Object { - "productName": "Linden 10 Round Wall Clock, Black", - "totalSales": 36.672, - }, - Object { - "productName": "Linden 10 Round Wall Clock, Black", - "totalSales": 30.56, - }, - Object { - "productName": "Linden 10 Round Wall Clock, Black", - "totalSales": 30.56, - }, - Object { - "productName": "Anderson Hickey Conga Table Tops & Accessories", - "totalSales": 24.368, - }, - Object { - "productName": "Plymouth Boxed Rubber Bands by Plymouth", - "totalSales": 23.55, - }, - Object { - "productName": "Vinyl Coated Wire Paper Clips in Organizer Box, 800/Box", - "totalSales": 18.368, - }, - Object { - "productName": "Wausau Papers Astrobrights Colored Envelopes", - "totalSales": 14.352, - }, - Object { - "productName": "Plymouth Boxed Rubber Bands by Plymouth", - "totalSales": 14.13, - }, - Object { - "productName": "Project Tote Personal File", - "totalSales": 14.03, - }, - Object { - "productName": "Plymouth Boxed Rubber Bands by Plymouth", - "totalSales": 11.304, - }, - Object { - "productName": "Magna Visual Magnetic Picture Hangers", - "totalSales": 9.64, - }, - Object { - "productName": "OIC #2 Pencils, Medium Soft", - "totalSales": 9.4, - }, - Object { - "productName": "Magna Visual Magnetic Picture Hangers", - "totalSales": 7.712, - }, - Object { - "productName": "OIC #2 Pencils, Medium Soft", - "totalSales": 3.76, - }, - Object { - "productName": "OIC #2 Pencils, Medium Soft", - "totalSales": 3.76, - }, - Object { - "productName": "Lexmark 20R1285 X6650 Wireless All-in-One Printer", - "totalSales": null, - }, -] -`; - exports[`Queries with the @cubejs-backend/snowflake-driver encrypted-pk filtering Customers: contains + dimensions, first 1`] = ` Array [ Object { diff --git a/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-export-bucket-azure-full.test.ts.snap b/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-export-bucket-azure-full.test.ts.snap index bd40134111d76..ea5eb82658a82 100644 --- a/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-export-bucket-azure-full.test.ts.snap +++ b/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-export-bucket-azure-full.test.ts.snap @@ -4670,6 +4670,472 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure SQL API: Rolling Window YTD (year + month + day + date_trunc IN) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure SQL API: Rolling Window YTD (year + month + day + date_trunc equal) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure SQL API: Rollup over exprs: rollup_over_exprs 1`] = ` Array [ Object { @@ -8126,14 +8592,6 @@ Array [ ] `; -exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure SQL API: metabase count cast to float32 from push down: metabase_count_cast_to_float32_from_push_down 1`] = ` -Array [ - Object { - "a0": 41, - }, -] -`; - exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure SQL API: post-aggregate percentage of total: post_aggregate_percentage_of_total 1`] = ` Array [ Object { @@ -8142,15 +8600,6 @@ Array [ ] `; -exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure SQL API: powerbi min max push down: powerbi_min_max_push_down 1`] = ` -Array [ - Object { - "a0": 2020-12-25T00:00:00.000Z, - "a1": 2020-01-01T00:00:00.000Z, - }, -] -`; - exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure SQL API: powerbi min max ungrouped flag: powerbi_min_max_ungrouped_flag 1`] = ` Array [ Object { @@ -8161,353 +8610,163 @@ Array [ ] `; -exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure SQL API: reuse params: reuse_params 1`] = ` +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure filtering Customers: contains + dimensions, first 1`] = ` Array [ Object { - "c0": 2020-01-01T00:00:00.000Z, - "m0": 17372, + "Customers.customerId": "AH-10465", + "Customers.customerName": "Customer 1", }, -] -`; - -exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure SQL API: ungrouped pre-agg: ungrouped_pre_agg 1`] = ` -Array [ Object { - "productName": "Canon PC1080F Personal Copier", - "totalSales": 2399.96, + "Customers.customerId": "AJ-10780", + "Customers.customerName": "Customer 2", }, Object { - "productName": "Logitech di_Novo Edge Keyboard", - "totalSales": 2249.91, + "Customers.customerId": "AS-10225", + "Customers.customerName": "Customer 3", }, Object { - "productName": "Global Adaptabilites Bookcase, Cherry/Storm Gray Finish", - "totalSales": 2154.9, + "Customers.customerId": "AW-10840", + "Customers.customerName": "Customer 4", }, Object { - "productName": "Google Nexus 5", - "totalSales": 1979.89, + "Customers.customerId": "BB-11545", + "Customers.customerName": "Customer 5", }, Object { - "productName": "Global Adaptabilites Bookcase, Cherry/Storm Gray Finish", - "totalSales": 1292.94, + "Customers.customerId": "BF-11020", + "Customers.customerName": "Customer 6", }, Object { - "productName": "Canon PC1080F Personal Copier", - "totalSales": 1199.98, + "Customers.customerId": "BF-11170", + "Customers.customerName": "Customer 7", }, Object { - "productName": "Hewlett Packard 610 Color Digital Copier / Printer", - "totalSales": 899.982, + "Customers.customerId": "BM-11650", + "Customers.customerName": "Customer 8", }, Object { - "productName": "Okidata C610n Printer", - "totalSales": 649, + "Customers.customerId": "BS-11380", + "Customers.customerName": "Customer 9", }, Object { - "productName": "Lexmark 20R1285 X6650 Wireless All-in-One Printer", - "totalSales": 600, + "Customers.customerId": "BS-11755", + "Customers.customerName": "Customer 10", }, Object { - "productName": "Google Nexus 6", - "totalSales": 539.97, + "Customers.customerId": "CA-12775", + "Customers.customerName": "Customer 11", }, Object { - "productName": "Google Nexus 7", - "totalSales": 539.97, + "Customers.customerId": "CC-12475", + "Customers.customerName": "Customer 12", }, Object { - "productName": "Harbour Creations 67200 Series Stacking Chairs", - "totalSales": 498.26, + "Customers.customerId": "CD-12280", + "Customers.customerName": "Customer 13", }, Object { - "productName": "DMI Eclipse Executive Suite Bookcases", - "totalSales": 400.784, + "Customers.customerId": "CS-12355", + "Customers.customerName": "Customer 14", }, Object { - "productName": "HTC One", - "totalSales": 239.976, + "Customers.customerId": "DB-13405", + "Customers.customerName": "Customer 15", }, Object { - "productName": "Iceberg Nesting Folding Chair, 19w x 6d x 43h", - "totalSales": 232.88, + "Customers.customerId": "DG-13300", + "Customers.customerName": "Customer 16", }, Object { - "productName": "Balt Solid Wood Rectangular Table", - "totalSales": 210.98, + "Customers.customerId": "DW-13480", + "Customers.customerName": "Customer 17", }, Object { - "productName": "Tyvek Side-Opening Peel & Seel Expanding Envelopes", - "totalSales": 180.96, + "Customers.customerId": "EM-14140", + "Customers.customerName": "Customer 18", }, Object { - "productName": "Panasonic KP-380BK Classic Electric Pencil Sharpener", - "totalSales": 179.9, + "Customers.customerId": "GA-14725", + "Customers.customerName": "Customer 19", }, Object { - "productName": "Harbour Creations 67200 Series Stacking Chairs", - "totalSales": 128.124, + "Customers.customerId": "GZ-14470", + "Customers.customerName": "Customer 20", }, Object { - "productName": "Harbour Creations 67200 Series Stacking Chairs", - "totalSales": 113.888, + "Customers.customerId": "HH-15010", + "Customers.customerName": "Customer 21", }, Object { - "productName": "Panasonic KP-380BK Classic Electric Pencil Sharpener", - "totalSales": 86.352, + "Customers.customerId": "HK-14890", + "Customers.customerName": "Customer 22", }, Object { - "productName": "Kingston Digital DataTraveler 16GB USB 2.2", - "totalSales": 71.6, + "Customers.customerId": "JH-15430", + "Customers.customerName": "Customer 23", }, Object { - "productName": "Linden 10 Round Wall Clock, Black", - "totalSales": 48.896, + "Customers.customerId": "JO-15550", + "Customers.customerName": "Customer 24", }, Object { - "productName": "Vinyl Coated Wire Paper Clips in Organizer Box, 800/Box", - "totalSales": 45.92, + "Customers.customerId": "JS-16030", + "Customers.customerName": "Customer 25", }, Object { - "productName": "Vinyl Coated Wire Paper Clips in Organizer Box, 800/Box", - "totalSales": 45.92, + "Customers.customerId": "JW-15220", + "Customers.customerName": "Customer 26", }, Object { - "productName": "Kingston Digital DataTraveler 16GB USB 2.0", - "totalSales": 44.75, + "Customers.customerId": "KL-16555", + "Customers.customerName": "Customer 27", }, Object { - "productName": "Kingston Digital DataTraveler 16GB USB 2.1", - "totalSales": 44.75, + "Customers.customerId": "KN-16705", + "Customers.customerName": "Customer 28", }, Object { - "productName": "Recycled Eldon Regeneration Jumbo File", - "totalSales": 39.296, + "Customers.customerId": "LC-17050", + "Customers.customerName": "Customer 29", }, Object { - "productName": "Linden 10 Round Wall Clock, Black", - "totalSales": 36.672, + "Customers.customerId": "LR-16915", + "Customers.customerName": "Customer 30", }, Object { - "productName": "Linden 10 Round Wall Clock, Black", - "totalSales": 30.56, + "Customers.customerId": "MC-17605", + "Customers.customerName": "Customer 31", }, Object { - "productName": "Linden 10 Round Wall Clock, Black", - "totalSales": 30.56, + "Customers.customerId": "MG-17650", + "Customers.customerName": "Customer 32", }, Object { - "productName": "Anderson Hickey Conga Table Tops & Accessories", - "totalSales": 24.368, + "Customers.customerId": "ML-17755", + "Customers.customerName": "Customer 33", }, Object { - "productName": "Plymouth Boxed Rubber Bands by Plymouth", - "totalSales": 23.55, + "Customers.customerId": "MM-18280", + "Customers.customerName": "Customer 34", }, Object { - "productName": "Vinyl Coated Wire Paper Clips in Organizer Box, 800/Box", - "totalSales": 18.368, + "Customers.customerId": "NP-18670", + "Customers.customerName": "Customer 35", }, Object { - "productName": "Wausau Papers Astrobrights Colored Envelopes", - "totalSales": 14.352, + "Customers.customerId": "PF-19165", + "Customers.customerName": "Customer 36", }, Object { - "productName": "Plymouth Boxed Rubber Bands by Plymouth", - "totalSales": 14.13, + "Customers.customerId": "SB-20185", + "Customers.customerName": "Customer 37", }, Object { - "productName": "Project Tote Personal File", - "totalSales": 14.03, + "Customers.customerId": "SS-20140", + "Customers.customerName": "Customer 38", }, Object { - "productName": "Plymouth Boxed Rubber Bands by Plymouth", - "totalSales": 11.304, - }, - Object { - "productName": "Magna Visual Magnetic Picture Hangers", - "totalSales": 9.64, - }, - Object { - "productName": "OIC #2 Pencils, Medium Soft", - "totalSales": 9.4, - }, - Object { - "productName": "Magna Visual Magnetic Picture Hangers", - "totalSales": 7.712, - }, - Object { - "productName": "OIC #2 Pencils, Medium Soft", - "totalSales": 3.76, - }, - Object { - "productName": "OIC #2 Pencils, Medium Soft", - "totalSales": 3.76, - }, - Object { - "productName": "Lexmark 20R1285 X6650 Wireless All-in-One Printer", - "totalSales": null, - }, -] -`; - -exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure filtering Customers: contains + dimensions, first 1`] = ` -Array [ - Object { - "Customers.customerId": "AH-10465", - "Customers.customerName": "Customer 1", - }, - Object { - "Customers.customerId": "AJ-10780", - "Customers.customerName": "Customer 2", - }, - Object { - "Customers.customerId": "AS-10225", - "Customers.customerName": "Customer 3", - }, - Object { - "Customers.customerId": "AW-10840", - "Customers.customerName": "Customer 4", - }, - Object { - "Customers.customerId": "BB-11545", - "Customers.customerName": "Customer 5", - }, - Object { - "Customers.customerId": "BF-11020", - "Customers.customerName": "Customer 6", - }, - Object { - "Customers.customerId": "BF-11170", - "Customers.customerName": "Customer 7", - }, - Object { - "Customers.customerId": "BM-11650", - "Customers.customerName": "Customer 8", - }, - Object { - "Customers.customerId": "BS-11380", - "Customers.customerName": "Customer 9", - }, - Object { - "Customers.customerId": "BS-11755", - "Customers.customerName": "Customer 10", - }, - Object { - "Customers.customerId": "CA-12775", - "Customers.customerName": "Customer 11", - }, - Object { - "Customers.customerId": "CC-12475", - "Customers.customerName": "Customer 12", - }, - Object { - "Customers.customerId": "CD-12280", - "Customers.customerName": "Customer 13", - }, - Object { - "Customers.customerId": "CS-12355", - "Customers.customerName": "Customer 14", - }, - Object { - "Customers.customerId": "DB-13405", - "Customers.customerName": "Customer 15", - }, - Object { - "Customers.customerId": "DG-13300", - "Customers.customerName": "Customer 16", - }, - Object { - "Customers.customerId": "DW-13480", - "Customers.customerName": "Customer 17", - }, - Object { - "Customers.customerId": "EM-14140", - "Customers.customerName": "Customer 18", - }, - Object { - "Customers.customerId": "GA-14725", - "Customers.customerName": "Customer 19", - }, - Object { - "Customers.customerId": "GZ-14470", - "Customers.customerName": "Customer 20", - }, - Object { - "Customers.customerId": "HH-15010", - "Customers.customerName": "Customer 21", - }, - Object { - "Customers.customerId": "HK-14890", - "Customers.customerName": "Customer 22", - }, - Object { - "Customers.customerId": "JH-15430", - "Customers.customerName": "Customer 23", - }, - Object { - "Customers.customerId": "JO-15550", - "Customers.customerName": "Customer 24", - }, - Object { - "Customers.customerId": "JS-16030", - "Customers.customerName": "Customer 25", - }, - Object { - "Customers.customerId": "JW-15220", - "Customers.customerName": "Customer 26", - }, - Object { - "Customers.customerId": "KL-16555", - "Customers.customerName": "Customer 27", - }, - Object { - "Customers.customerId": "KN-16705", - "Customers.customerName": "Customer 28", - }, - Object { - "Customers.customerId": "LC-17050", - "Customers.customerName": "Customer 29", - }, - Object { - "Customers.customerId": "LR-16915", - "Customers.customerName": "Customer 30", - }, - Object { - "Customers.customerId": "MC-17605", - "Customers.customerName": "Customer 31", - }, - Object { - "Customers.customerId": "MG-17650", - "Customers.customerName": "Customer 32", - }, - Object { - "Customers.customerId": "ML-17755", - "Customers.customerName": "Customer 33", - }, - Object { - "Customers.customerId": "MM-18280", - "Customers.customerName": "Customer 34", - }, - Object { - "Customers.customerId": "NP-18670", - "Customers.customerName": "Customer 35", - }, - Object { - "Customers.customerId": "PF-19165", - "Customers.customerName": "Customer 36", - }, - Object { - "Customers.customerId": "SB-20185", - "Customers.customerName": "Customer 37", - }, - Object { - "Customers.customerId": "SS-20140", - "Customers.customerName": "Customer 38", - }, - Object { - "Customers.customerId": "TB-21175", - "Customers.customerName": "Customer 39", + "Customers.customerId": "TB-21175", + "Customers.customerName": "Customer 39", }, Object { "Customers.customerId": "TS-21205", @@ -11357,6 +11616,1097 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure querying BigECommerce: rolling window YTD (month + week + day + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure querying BigECommerce: rolling window YTD (month + week + day) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure querying BigECommerce: rolling window YTD (month + week + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure querying BigECommerce: rolling window YTD (month + week) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure querying BigECommerce: rolling window YTD (month) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure querying BigECommerce: rolling window YTD without granularity 1`] = ` +Array [ + Object { + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure querying BigECommerce: rolling window by 2 day 1`] = ` Array [ Object { diff --git a/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-export-bucket-azure-prefix-full.test.ts.snap b/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-export-bucket-azure-prefix-full.test.ts.snap index 31f905f778f3f..f08e30ba9eace 100644 --- a/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-export-bucket-azure-prefix-full.test.ts.snap +++ b/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-export-bucket-azure-prefix-full.test.ts.snap @@ -4670,6 +4670,472 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure-prefix SQL API: Rolling Window YTD (year + month + day + date_trunc IN) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure-prefix SQL API: Rolling Window YTD (year + month + day + date_trunc equal) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure-prefix SQL API: Rollup over exprs: rollup_over_exprs 1`] = ` Array [ Object { @@ -8126,14 +8592,6 @@ Array [ ] `; -exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure-prefix SQL API: metabase count cast to float32 from push down: metabase_count_cast_to_float32_from_push_down 1`] = ` -Array [ - Object { - "a0": 41, - }, -] -`; - exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure-prefix SQL API: post-aggregate percentage of total: post_aggregate_percentage_of_total 1`] = ` Array [ Object { @@ -8142,15 +8600,6 @@ Array [ ] `; -exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure-prefix SQL API: powerbi min max push down: powerbi_min_max_push_down 1`] = ` -Array [ - Object { - "a0": 2020-12-25T00:00:00.000Z, - "a1": 2020-01-01T00:00:00.000Z, - }, -] -`; - exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure-prefix SQL API: powerbi min max ungrouped flag: powerbi_min_max_ungrouped_flag 1`] = ` Array [ Object { @@ -8161,353 +8610,163 @@ Array [ ] `; -exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure-prefix SQL API: reuse params: reuse_params 1`] = ` +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure-prefix filtering Customers: contains + dimensions, first 1`] = ` Array [ Object { - "c0": 2020-01-01T00:00:00.000Z, - "m0": 17372, + "Customers.customerId": "AH-10465", + "Customers.customerName": "Customer 1", }, -] -`; - -exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure-prefix SQL API: ungrouped pre-agg: ungrouped_pre_agg 1`] = ` -Array [ Object { - "productName": "Canon PC1080F Personal Copier", - "totalSales": 2399.96, + "Customers.customerId": "AJ-10780", + "Customers.customerName": "Customer 2", }, Object { - "productName": "Logitech di_Novo Edge Keyboard", - "totalSales": 2249.91, + "Customers.customerId": "AS-10225", + "Customers.customerName": "Customer 3", }, Object { - "productName": "Global Adaptabilites Bookcase, Cherry/Storm Gray Finish", - "totalSales": 2154.9, + "Customers.customerId": "AW-10840", + "Customers.customerName": "Customer 4", }, Object { - "productName": "Google Nexus 5", - "totalSales": 1979.89, + "Customers.customerId": "BB-11545", + "Customers.customerName": "Customer 5", }, Object { - "productName": "Global Adaptabilites Bookcase, Cherry/Storm Gray Finish", - "totalSales": 1292.94, + "Customers.customerId": "BF-11020", + "Customers.customerName": "Customer 6", }, Object { - "productName": "Canon PC1080F Personal Copier", - "totalSales": 1199.98, + "Customers.customerId": "BF-11170", + "Customers.customerName": "Customer 7", }, Object { - "productName": "Hewlett Packard 610 Color Digital Copier / Printer", - "totalSales": 899.982, + "Customers.customerId": "BM-11650", + "Customers.customerName": "Customer 8", }, Object { - "productName": "Okidata C610n Printer", - "totalSales": 649, + "Customers.customerId": "BS-11380", + "Customers.customerName": "Customer 9", }, Object { - "productName": "Lexmark 20R1285 X6650 Wireless All-in-One Printer", - "totalSales": 600, + "Customers.customerId": "BS-11755", + "Customers.customerName": "Customer 10", }, Object { - "productName": "Google Nexus 6", - "totalSales": 539.97, + "Customers.customerId": "CA-12775", + "Customers.customerName": "Customer 11", }, Object { - "productName": "Google Nexus 7", - "totalSales": 539.97, + "Customers.customerId": "CC-12475", + "Customers.customerName": "Customer 12", }, Object { - "productName": "Harbour Creations 67200 Series Stacking Chairs", - "totalSales": 498.26, + "Customers.customerId": "CD-12280", + "Customers.customerName": "Customer 13", }, Object { - "productName": "DMI Eclipse Executive Suite Bookcases", - "totalSales": 400.784, + "Customers.customerId": "CS-12355", + "Customers.customerName": "Customer 14", }, Object { - "productName": "HTC One", - "totalSales": 239.976, + "Customers.customerId": "DB-13405", + "Customers.customerName": "Customer 15", }, Object { - "productName": "Iceberg Nesting Folding Chair, 19w x 6d x 43h", - "totalSales": 232.88, + "Customers.customerId": "DG-13300", + "Customers.customerName": "Customer 16", }, Object { - "productName": "Balt Solid Wood Rectangular Table", - "totalSales": 210.98, + "Customers.customerId": "DW-13480", + "Customers.customerName": "Customer 17", }, Object { - "productName": "Tyvek Side-Opening Peel & Seel Expanding Envelopes", - "totalSales": 180.96, + "Customers.customerId": "EM-14140", + "Customers.customerName": "Customer 18", }, Object { - "productName": "Panasonic KP-380BK Classic Electric Pencil Sharpener", - "totalSales": 179.9, + "Customers.customerId": "GA-14725", + "Customers.customerName": "Customer 19", }, Object { - "productName": "Harbour Creations 67200 Series Stacking Chairs", - "totalSales": 128.124, + "Customers.customerId": "GZ-14470", + "Customers.customerName": "Customer 20", }, Object { - "productName": "Harbour Creations 67200 Series Stacking Chairs", - "totalSales": 113.888, + "Customers.customerId": "HH-15010", + "Customers.customerName": "Customer 21", }, Object { - "productName": "Panasonic KP-380BK Classic Electric Pencil Sharpener", - "totalSales": 86.352, + "Customers.customerId": "HK-14890", + "Customers.customerName": "Customer 22", }, Object { - "productName": "Kingston Digital DataTraveler 16GB USB 2.2", - "totalSales": 71.6, + "Customers.customerId": "JH-15430", + "Customers.customerName": "Customer 23", }, Object { - "productName": "Linden 10 Round Wall Clock, Black", - "totalSales": 48.896, + "Customers.customerId": "JO-15550", + "Customers.customerName": "Customer 24", }, Object { - "productName": "Vinyl Coated Wire Paper Clips in Organizer Box, 800/Box", - "totalSales": 45.92, + "Customers.customerId": "JS-16030", + "Customers.customerName": "Customer 25", }, Object { - "productName": "Vinyl Coated Wire Paper Clips in Organizer Box, 800/Box", - "totalSales": 45.92, + "Customers.customerId": "JW-15220", + "Customers.customerName": "Customer 26", }, Object { - "productName": "Kingston Digital DataTraveler 16GB USB 2.0", - "totalSales": 44.75, + "Customers.customerId": "KL-16555", + "Customers.customerName": "Customer 27", }, Object { - "productName": "Kingston Digital DataTraveler 16GB USB 2.1", - "totalSales": 44.75, + "Customers.customerId": "KN-16705", + "Customers.customerName": "Customer 28", }, Object { - "productName": "Recycled Eldon Regeneration Jumbo File", - "totalSales": 39.296, + "Customers.customerId": "LC-17050", + "Customers.customerName": "Customer 29", }, Object { - "productName": "Linden 10 Round Wall Clock, Black", - "totalSales": 36.672, + "Customers.customerId": "LR-16915", + "Customers.customerName": "Customer 30", }, Object { - "productName": "Linden 10 Round Wall Clock, Black", - "totalSales": 30.56, + "Customers.customerId": "MC-17605", + "Customers.customerName": "Customer 31", }, Object { - "productName": "Linden 10 Round Wall Clock, Black", - "totalSales": 30.56, + "Customers.customerId": "MG-17650", + "Customers.customerName": "Customer 32", }, Object { - "productName": "Anderson Hickey Conga Table Tops & Accessories", - "totalSales": 24.368, + "Customers.customerId": "ML-17755", + "Customers.customerName": "Customer 33", }, Object { - "productName": "Plymouth Boxed Rubber Bands by Plymouth", - "totalSales": 23.55, + "Customers.customerId": "MM-18280", + "Customers.customerName": "Customer 34", }, Object { - "productName": "Vinyl Coated Wire Paper Clips in Organizer Box, 800/Box", - "totalSales": 18.368, + "Customers.customerId": "NP-18670", + "Customers.customerName": "Customer 35", }, Object { - "productName": "Wausau Papers Astrobrights Colored Envelopes", - "totalSales": 14.352, + "Customers.customerId": "PF-19165", + "Customers.customerName": "Customer 36", }, Object { - "productName": "Plymouth Boxed Rubber Bands by Plymouth", - "totalSales": 14.13, + "Customers.customerId": "SB-20185", + "Customers.customerName": "Customer 37", }, Object { - "productName": "Project Tote Personal File", - "totalSales": 14.03, + "Customers.customerId": "SS-20140", + "Customers.customerName": "Customer 38", }, Object { - "productName": "Plymouth Boxed Rubber Bands by Plymouth", - "totalSales": 11.304, - }, - Object { - "productName": "Magna Visual Magnetic Picture Hangers", - "totalSales": 9.64, - }, - Object { - "productName": "OIC #2 Pencils, Medium Soft", - "totalSales": 9.4, - }, - Object { - "productName": "Magna Visual Magnetic Picture Hangers", - "totalSales": 7.712, - }, - Object { - "productName": "OIC #2 Pencils, Medium Soft", - "totalSales": 3.76, - }, - Object { - "productName": "OIC #2 Pencils, Medium Soft", - "totalSales": 3.76, - }, - Object { - "productName": "Lexmark 20R1285 X6650 Wireless All-in-One Printer", - "totalSales": null, - }, -] -`; - -exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure-prefix filtering Customers: contains + dimensions, first 1`] = ` -Array [ - Object { - "Customers.customerId": "AH-10465", - "Customers.customerName": "Customer 1", - }, - Object { - "Customers.customerId": "AJ-10780", - "Customers.customerName": "Customer 2", - }, - Object { - "Customers.customerId": "AS-10225", - "Customers.customerName": "Customer 3", - }, - Object { - "Customers.customerId": "AW-10840", - "Customers.customerName": "Customer 4", - }, - Object { - "Customers.customerId": "BB-11545", - "Customers.customerName": "Customer 5", - }, - Object { - "Customers.customerId": "BF-11020", - "Customers.customerName": "Customer 6", - }, - Object { - "Customers.customerId": "BF-11170", - "Customers.customerName": "Customer 7", - }, - Object { - "Customers.customerId": "BM-11650", - "Customers.customerName": "Customer 8", - }, - Object { - "Customers.customerId": "BS-11380", - "Customers.customerName": "Customer 9", - }, - Object { - "Customers.customerId": "BS-11755", - "Customers.customerName": "Customer 10", - }, - Object { - "Customers.customerId": "CA-12775", - "Customers.customerName": "Customer 11", - }, - Object { - "Customers.customerId": "CC-12475", - "Customers.customerName": "Customer 12", - }, - Object { - "Customers.customerId": "CD-12280", - "Customers.customerName": "Customer 13", - }, - Object { - "Customers.customerId": "CS-12355", - "Customers.customerName": "Customer 14", - }, - Object { - "Customers.customerId": "DB-13405", - "Customers.customerName": "Customer 15", - }, - Object { - "Customers.customerId": "DG-13300", - "Customers.customerName": "Customer 16", - }, - Object { - "Customers.customerId": "DW-13480", - "Customers.customerName": "Customer 17", - }, - Object { - "Customers.customerId": "EM-14140", - "Customers.customerName": "Customer 18", - }, - Object { - "Customers.customerId": "GA-14725", - "Customers.customerName": "Customer 19", - }, - Object { - "Customers.customerId": "GZ-14470", - "Customers.customerName": "Customer 20", - }, - Object { - "Customers.customerId": "HH-15010", - "Customers.customerName": "Customer 21", - }, - Object { - "Customers.customerId": "HK-14890", - "Customers.customerName": "Customer 22", - }, - Object { - "Customers.customerId": "JH-15430", - "Customers.customerName": "Customer 23", - }, - Object { - "Customers.customerId": "JO-15550", - "Customers.customerName": "Customer 24", - }, - Object { - "Customers.customerId": "JS-16030", - "Customers.customerName": "Customer 25", - }, - Object { - "Customers.customerId": "JW-15220", - "Customers.customerName": "Customer 26", - }, - Object { - "Customers.customerId": "KL-16555", - "Customers.customerName": "Customer 27", - }, - Object { - "Customers.customerId": "KN-16705", - "Customers.customerName": "Customer 28", - }, - Object { - "Customers.customerId": "LC-17050", - "Customers.customerName": "Customer 29", - }, - Object { - "Customers.customerId": "LR-16915", - "Customers.customerName": "Customer 30", - }, - Object { - "Customers.customerId": "MC-17605", - "Customers.customerName": "Customer 31", - }, - Object { - "Customers.customerId": "MG-17650", - "Customers.customerName": "Customer 32", - }, - Object { - "Customers.customerId": "ML-17755", - "Customers.customerName": "Customer 33", - }, - Object { - "Customers.customerId": "MM-18280", - "Customers.customerName": "Customer 34", - }, - Object { - "Customers.customerId": "NP-18670", - "Customers.customerName": "Customer 35", - }, - Object { - "Customers.customerId": "PF-19165", - "Customers.customerName": "Customer 36", - }, - Object { - "Customers.customerId": "SB-20185", - "Customers.customerName": "Customer 37", - }, - Object { - "Customers.customerId": "SS-20140", - "Customers.customerName": "Customer 38", - }, - Object { - "Customers.customerId": "TB-21175", - "Customers.customerName": "Customer 39", + "Customers.customerId": "TB-21175", + "Customers.customerName": "Customer 39", }, Object { "Customers.customerId": "TS-21205", @@ -11162,6 +11421,1097 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure-prefix querying BigECommerce: rolling window YTD (month + week + day + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure-prefix querying BigECommerce: rolling window YTD (month + week + day) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure-prefix querying BigECommerce: rolling window YTD (month + week + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure-prefix querying BigECommerce: rolling window YTD (month + week) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-03-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-04-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-06-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-09-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-10-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-11-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure-prefix querying BigECommerce: rolling window YTD (month) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure-prefix querying BigECommerce: rolling window YTD without granularity 1`] = ` +Array [ + Object { + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure-prefix querying BigECommerce: rolling window by 2 day 1`] = ` Array [ Object { diff --git a/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-export-bucket-azure-via-storage-integration-full.test.ts.snap b/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-export-bucket-azure-via-storage-integration-full.test.ts.snap index 876ca6d72c6e7..0114e5f88009f 100644 --- a/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-export-bucket-azure-via-storage-integration-full.test.ts.snap +++ b/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-export-bucket-azure-via-storage-integration-full.test.ts.snap @@ -4670,6 +4670,472 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure-via-storage-integration SQL API: Rolling Window YTD (year + month + day + date_trunc IN) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure-via-storage-integration SQL API: Rolling Window YTD (year + month + day + date_trunc equal) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure-via-storage-integration SQL API: Rollup over exprs: rollup_over_exprs 1`] = ` Array [ Object { @@ -11357,6 +11823,1097 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure-via-storage-integration querying BigECommerce: rolling window YTD (month + week + day + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure-via-storage-integration querying BigECommerce: rolling window YTD (month + week + day) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure-via-storage-integration querying BigECommerce: rolling window YTD (month + week + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure-via-storage-integration querying BigECommerce: rolling window YTD (month + week) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-03-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-04-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-06-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-09-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-10-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-11-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure-via-storage-integration querying BigECommerce: rolling window YTD (month) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure-via-storage-integration querying BigECommerce: rolling window YTD without granularity 1`] = ` +Array [ + Object { + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-azure-via-storage-integration querying BigECommerce: rolling window by 2 day 1`] = ` Array [ Object { diff --git a/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-export-bucket-gcs-full.test.ts.snap b/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-export-bucket-gcs-full.test.ts.snap index f271de780bbdb..5e0801efc9adc 100644 --- a/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-export-bucket-gcs-full.test.ts.snap +++ b/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-export-bucket-gcs-full.test.ts.snap @@ -4670,6 +4670,472 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-gcs SQL API: Rolling Window YTD (year + month + day + date_trunc IN) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-gcs SQL API: Rolling Window YTD (year + month + day + date_trunc equal) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-gcs SQL API: Rollup over exprs: rollup_over_exprs 1`] = ` Array [ Object { @@ -11357,6 +11823,1097 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-gcs querying BigECommerce: rolling window YTD (month + week + day + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-gcs querying BigECommerce: rolling window YTD (month + week + day) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-gcs querying BigECommerce: rolling window YTD (month + week + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-03-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-04-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-06-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-09-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-10-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-11-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-gcs querying BigECommerce: rolling window YTD (month + week) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-gcs querying BigECommerce: rolling window YTD (month) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-gcs querying BigECommerce: rolling window YTD without granularity 1`] = ` +Array [ + Object { + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-gcs querying BigECommerce: rolling window by 2 day 1`] = ` Array [ Object { diff --git a/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-export-bucket-gcs-prefix-full.test.ts.snap b/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-export-bucket-gcs-prefix-full.test.ts.snap index f19a5725b3af5..5890900ba270f 100644 --- a/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-export-bucket-gcs-prefix-full.test.ts.snap +++ b/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-export-bucket-gcs-prefix-full.test.ts.snap @@ -4670,6 +4670,472 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-gcs-prefix SQL API: Rolling Window YTD (year + month + day + date_trunc IN) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-gcs-prefix SQL API: Rolling Window YTD (year + month + day + date_trunc equal) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-gcs-prefix SQL API: Rollup over exprs: rollup_over_exprs 1`] = ` Array [ Object { @@ -11162,6 +11628,1097 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-gcs-prefix querying BigECommerce: rolling window YTD (month + week + day + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-gcs-prefix querying BigECommerce: rolling window YTD (month + week + day) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-gcs-prefix querying BigECommerce: rolling window YTD (month + week + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-gcs-prefix querying BigECommerce: rolling window YTD (month + week) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-03-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-04-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-06-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-09-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-10-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-11-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-gcs-prefix querying BigECommerce: rolling window YTD (month) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-gcs-prefix querying BigECommerce: rolling window YTD without granularity 1`] = ` +Array [ + Object { + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-gcs-prefix querying BigECommerce: rolling window by 2 day 1`] = ` Array [ Object { diff --git a/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-export-bucket-s3-full.test.ts.snap b/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-export-bucket-s3-full.test.ts.snap index 218ba02038682..224bf929ebad7 100644 --- a/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-export-bucket-s3-full.test.ts.snap +++ b/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-export-bucket-s3-full.test.ts.snap @@ -4670,6 +4670,472 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-s3 SQL API: Rolling Window YTD (year + month + day + date_trunc IN) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-s3 SQL API: Rolling Window YTD (year + month + day + date_trunc equal) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-s3 SQL API: Rollup over exprs: rollup_over_exprs 1`] = ` Array [ Object { @@ -11357,6 +11823,1097 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-s3 querying BigECommerce: rolling window YTD (month + week + day + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-s3 querying BigECommerce: rolling window YTD (month + week + day) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-s3 querying BigECommerce: rolling window YTD (month + week + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-s3 querying BigECommerce: rolling window YTD (month + week) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-03-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-04-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-06-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-09-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-10-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-11-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-s3 querying BigECommerce: rolling window YTD (month) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-s3 querying BigECommerce: rolling window YTD without granularity 1`] = ` +Array [ + Object { + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + exports[`Queries with the @cubejs-backend/snowflake-driver export-bucket-s3 querying BigECommerce: rolling window by 2 day 1`] = ` Array [ Object { diff --git a/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-full.test.ts.snap b/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-full.test.ts.snap index e22c2af7604a0..2226fdff96a4c 100644 --- a/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-full.test.ts.snap +++ b/packages/cubejs-testing-drivers/test/__snapshots__/snowflake-full.test.ts.snap @@ -4670,6 +4670,472 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/snowflake-driver SQL API: Rolling Window YTD (year + month + day + date_trunc IN) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver SQL API: Rolling Window YTD (year + month + day + date_trunc equal) 1`] = ` +Array [ + Object { + "orderDateD": 2020-01-01T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-01-23T00:00:00.000Z, + "orderDateM": 2020-01-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-02-16T00:00:00.000Z, + "orderDateM": 2020-02-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-17T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-03-26T00:00:00.000Z, + "orderDateM": 2020-03-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-04-10T00:00:00.000Z, + "orderDateM": 2020-04-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-13T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-14T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-05-27T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-05-29T00:00:00.000Z, + "orderDateM": 2020-05-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-03T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-10T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-11T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-15T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-17T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-06-25T00:00:00.000Z, + "orderDateM": 2020-06-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-01T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-02T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-08T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-09-17T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-09-23T00:00:00.000Z, + "orderDateM": 2020-09-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-12T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-10-19T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-10-30T00:00:00.000Z, + "orderDateM": 2020-10-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-02T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-05T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-06T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-11T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-12T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-16T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-11-21T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-11-28T00:00:00.000Z, + "orderDateM": 2020-11-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-01T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-02T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-04T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-14T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "2", + }, + Object { + "orderDateD": 2020-12-24T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, + Object { + "orderDateD": 2020-12-25T00:00:00.000Z, + "orderDateM": 2020-12-01T00:00:00.000Z, + "orderDateY": 2020-01-01T00:00:00.000Z, + "rollingCountYTD": "1", + }, +] +`; + exports[`Queries with the @cubejs-backend/snowflake-driver SQL API: Rollup over exprs: rollup_over_exprs 1`] = ` Array [ Object { @@ -11357,6 +11823,1097 @@ Array [ ] `; +exports[`Queries with the @cubejs-backend/snowflake-driver querying BigECommerce: rolling window YTD (month + week + day + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver querying BigECommerce: rolling window YTD (month + week + day) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-06T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-06T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-13T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-13T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "1", + }, + Object { + "BigECommerce.orderDate": "2020-01-20T00:00:00.000", + "BigECommerce.orderDate.day": "2020-01-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-20T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-13T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-07T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-16T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-14T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-08T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-09T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-20T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-06T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-15T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-12T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-25T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-05T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-04T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-10T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-11T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-10T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-22T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-21T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-02T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-19T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-03T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-03T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-18T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-17T00:00:00.000", + "BigECommerce.orderDate.day": "2020-02-23T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-17T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.day": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver querying BigECommerce: rolling window YTD (month + week + no gran) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2019-12-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-01-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-02-24T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-03-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-04-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-06-29T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-27T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-31T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-09-28T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-10-26T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-11-30T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver querying BigECommerce: rolling window YTD (month + week) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.week": "2019-12-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-01-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-02-24T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-03-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-04-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-06-29T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-07-27T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-08-31T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-09-28T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-10-26T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.week": "2020-11-30T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver querying BigECommerce: rolling window YTD (month) 1`] = ` +Array [ + Object { + "BigECommerce.orderDate": "2020-01-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-01-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "2", + }, + Object { + "BigECommerce.orderDate": "2020-02-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-02-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "3", + }, + Object { + "BigECommerce.orderDate": "2020-03-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-03-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "5", + }, + Object { + "BigECommerce.orderDate": "2020-04-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-04-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "6", + }, + Object { + "BigECommerce.orderDate": "2020-05-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-05-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "11", + }, + Object { + "BigECommerce.orderDate": "2020-06-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-06-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-07-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-07-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-08-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-08-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "18", + }, + Object { + "BigECommerce.orderDate": "2020-09-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-09-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "24", + }, + Object { + "BigECommerce.orderDate": "2020-10-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-10-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "28", + }, + Object { + "BigECommerce.orderDate": "2020-11-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-11-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "37", + }, + Object { + "BigECommerce.orderDate": "2020-12-01T00:00:00.000", + "BigECommerce.orderDate.month": "2020-12-01T00:00:00.000", + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + +exports[`Queries with the @cubejs-backend/snowflake-driver querying BigECommerce: rolling window YTD without granularity 1`] = ` +Array [ + Object { + "BigECommerce.rollingCountYTD": "44", + }, +] +`; + exports[`Queries with the @cubejs-backend/snowflake-driver querying BigECommerce: rolling window by 2 day 1`] = ` Array [ Object {