@malloydata/malloy 0.0.94-dev231006230622 → 0.0.94-dev231011004826

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -37,6 +37,7 @@ export declare abstract class Dialect {
37
37
  abstract supportsQualify: boolean;
38
38
  abstract supportsSafeCast: boolean;
39
39
  abstract supportsNesting: boolean;
40
+ cantPartitionWindowFunctionsOnExpressions: boolean;
40
41
  abstract getGlobalFunctionDef(name: string): DialectFunctionOverloadDef[] | undefined;
41
42
  abstract quoteTablePath(tablePath: string): string;
42
43
  abstract sqlGroupSetTable(groupSetCount: number): string;
@@ -52,6 +52,13 @@ function qtz(qi) {
52
52
  }
53
53
  exports.qtz = qtz;
54
54
  class Dialect {
55
+ constructor() {
56
+ // -- we should add flags with default values from now on so as to not break
57
+ // dialects outside our repository
58
+ //
59
+ // StandardSQL dialects can't partition on expression in window functions
60
+ this.cantPartitionWindowFunctionsOnExpressions = false;
61
+ }
55
62
  sqlFinalStage(_lastStageName, _fields) {
56
63
  throw new Error('Dialect has no final Stage but called Anyway');
57
64
  }
@@ -20,6 +20,7 @@ export declare class StandardSQLDialect extends Dialect {
20
20
  supportsQualify: boolean;
21
21
  supportsSafeCast: boolean;
22
22
  supportsNesting: boolean;
23
+ cantPartitionWindowFunctionsOnExpressions: boolean;
23
24
  quoteTablePath(tablePath: string): string;
24
25
  sqlGroupSetTable(groupSetCount: number): string;
25
26
  sqlAnyValue(groupSet: number, fieldName: string): string;
@@ -92,6 +92,7 @@ class StandardSQLDialect extends dialect_1.Dialect {
92
92
  this.supportsQualify = true;
93
93
  this.supportsSafeCast = true;
94
94
  this.supportsNesting = true;
95
+ this.cantPartitionWindowFunctionsOnExpressions = true;
95
96
  this.keywords = `
96
97
  ALL
97
98
  AND