@memberjunction/generic-database-provider 6.1.4 → 6.1.5

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.
@@ -13,22 +13,54 @@ export interface PagingWrappedSQL {
13
13
  /** The page size (same as maxRows input) */
14
14
  PageSize: number;
15
15
  }
16
+ /**
17
+ * How a requested row cap was applied.
18
+ *
19
+ * - `top` / `limit` / `fetch`: a `TOP n`, `LIMIT n`, or `OFFSET 0 ROWS FETCH NEXT n ROWS ONLY`
20
+ * clause in the statement itself.
21
+ * - `own-cap`: the statement's own cap was already as tight or tighter, so it was left as is.
22
+ * - `derived-table`: the statement was capped as a derived table.
23
+ * - `none`: no cap was applied; {@link RowCapOutcome.Reason} says why.
24
+ */
25
+ export type RowCapMethod = 'top' | 'limit' | 'fetch' | 'own-cap' | 'derived-table' | 'none';
26
+ /** Whether a requested row cap holds for the rendered SQL, and how. */
27
+ export interface RowCapOutcome {
28
+ /** True when the rendered SQL returns at most the requested number of rows. */
29
+ Applied: boolean;
30
+ Method: RowCapMethod;
31
+ /** Why no cap was applied; `null` when one was. */
32
+ Reason: string | null;
33
+ }
34
+ /** The capped SQL and the outcome, from {@link QueryPagingEngine.ApplyMaxRows}. */
35
+ export interface RowCapResult {
36
+ SQL: string;
37
+ Outcome: RowCapOutcome;
38
+ }
16
39
  /**
17
40
  * Handles server-side pagination for query SQL by applying platform-specific
18
41
  * paging clauses.
19
42
  *
20
- * **Data SQL** — appends OFFSET/FETCH (SQL Server) or LIMIT/OFFSET (PostgreSQL)
21
- * directly to the original SQL. The query is not wrapped in a CTE, so all column
22
- * scopes, ORDER BY references, and table aliases remain valid. TOP is stripped on
23
- * SQL Server since it conflicts with OFFSET.
43
+ * The statement is read from tokens ({@link AnalyzePagingShape}), so paging works the same way
44
+ * on SQL the AST parser cannot read, and the query's own text is kept as written: nothing is
45
+ * re-emitted from a syntax tree.
46
+ *
47
+ * **The query's own row cap is part of what it means.** `StartRow` and `MaxRows` page within the
48
+ * capped result, so the smaller of the query's cap and `MaxRows` wins, and the total row count is
49
+ * the size of the capped result. A numeric cap (`TOP n`, `LIMIT n [OFFSET k]`, `OFFSET k … FETCH
50
+ * NEXT n`) is replaced by the page's own clause with the arithmetic folded in; a page past the
51
+ * cap is an empty result. Any other cap (`TOP … PERCENT`, `WITH TIES`, an expression) is kept, and
52
+ * the query is paged as a derived table.
24
53
  *
25
- * **Count SQL** — wraps the original SQL (minus ORDER BY) in a CTE and produces
26
- * `SELECT COUNT(*) AS TotalRowCount FROM [__count]`. ORDER BY is irrelevant for
27
- * counting and must be removed since SQL Server forbids it in CTEs without TOP.
54
+ * **Data SQL** — appends OFFSET/FETCH (SQL Server) or LIMIT/OFFSET (PostgreSQL) to the
55
+ * statement, after its ORDER BY (a default one is added when it has none) and before any clause
56
+ * that must stay last (`OPTION (…)`, `FOR UPDATE`). Column scopes, ORDER BY references and table
57
+ * aliases stay valid because the query is not wrapped.
28
58
  *
29
- * This approach eliminates the need for ORDER BY remapping (mapping column
30
- * references from the inner query scope to the outer CTE scope), which was the
31
- * primary source of paging bugs.
59
+ * **Count SQL** — puts the query (without its ORDER BY, unless its own cap needs it) in a
60
+ * `[__count]` CTE beside the query's own CTEs and selects `COUNT(*) AS TotalRowCount`.
61
+ *
62
+ * A query that ends in `FOR JSON` / `FOR XML` returns a document, not rows, and cannot be paged;
63
+ * asking to page one is an error.
32
64
  */
33
65
  export declare class QueryPagingEngine {
34
66
  /**
@@ -42,111 +74,116 @@ export declare class QueryPagingEngine {
42
74
  */
43
75
  static WrapWithPaging(resolvedSQL: string, startRow: number, maxRows: number, platform: DatabasePlatform): PagingWrappedSQL;
44
76
  /**
45
- * Applies a row cap to the outermost SELECT.
77
+ * Applies a row cap to the outermost SELECT: the result returns at most `maxRows` rows.
46
78
  *
47
- * `maxRows` is treated as a hard ceiling: the result is guaranteed to
48
- * return at most `maxRows` rows whenever the SQL shape can be capped
49
- * without corrupting the query.
79
+ * The statement is edited in place, from tokens, so the caller's SQL is kept exactly as
80
+ * written apart from the cap, and SQL the AST parser cannot read is capped the same way:
81
+ * - No cap of its own: `TOP n` goes after `SELECT [ALL | DISTINCT]` on SQL Server, and
82
+ * `LIMIT n` at the end on PostgreSQL. A SQL Server set operation (which has no single
83
+ * SELECT to put TOP on) gets `OFFSET 0 ROWS FETCH NEXT n ROWS ONLY` after its ORDER BY.
84
+ * - A numeric cap of its own: the tighter of the two wins.
85
+ * - Any other cap of its own (`TOP … PERCENT`, `WITH TIES`, an expression, caps on more than
86
+ * one branch): the statement is capped as a derived table.
87
+ * Clauses that must stay last (`OPTION (…)`, `FOR UPDATE`) stay last.
50
88
  *
51
- * Strategy:
52
- * 1. Parse via AST. If the outermost SELECT has no existing cap,
53
- * inject `TOP N` (SQL Server) or `LIMIT N` (PostgreSQL).
54
- * 2. If an existing numeric `TOP`/`LIMIT` is present, reduce it to
55
- * `min(existing, maxRows)`. The tighter cap wins.
56
- * 3. If the AST recognizes the shape but can't inject (`TOP PERCENT`,
57
- * non-numeric `TOP`, `UNION`, `WITH TIES`, etc.), wrap with an
58
- * outer `SELECT TOP N * FROM (…) AS _mj_capped` (or LIMIT on PG).
59
- * 4. If the parser can't handle the input but the SQL is CTE-headed,
60
- * append `OFFSET 0 ROWS FETCH NEXT N ROWS ONLY` via {@link buildDataSQL}.
61
- * 5. Shapes that can't legally appear inside a derived table
62
- * (`FOR JSON`, `FOR XML`, `OPTION (...)`, `SELECT INTO`,
63
- * mutations) are returned unchanged — the cap is moot
64
- * (FOR JSON/XML return one row) or the validator should have
65
- * rejected them earlier (mutations, SELECT INTO).
89
+ * A statement that ends in `FOR JSON` / `FOR XML` returns one document built from its rows;
90
+ * it is capped in place (bounding the rows the document is built from) and left unchanged
91
+ * where only a derived table or a set-operation clause could cap it. Anything that is not a
92
+ * single read query (a write, `SELECT … INTO`) is left unchanged; the render pipeline refuses
93
+ * those before this point anyway.
66
94
  *
67
- * Non-positive, non-finite, or fractional `maxRows` are sanitized
68
- * (`<= 0` and non-finite are no-ops; fractional values are floored).
95
+ * Non-positive, non-finite, or fractional `maxRows` are sanitized (`<= 0` and non-finite are
96
+ * no-ops; fractional values are floored).
69
97
  */
70
98
  static WrapWithMaxRows(resolvedSQL: string, maxRows: number, platform: DatabasePlatform): string;
71
99
  /**
72
- * Wraps `sql` in an outer SELECT that enforces the row cap.
73
- * Used when the AST recognises the shape but cannot inject the cap
74
- * cleanly, or when the AST can't parse the input but the SQL is known
75
- * to be wrap-safe (no FOR JSON/FOR XML/OPTION at top level).
76
- *
77
- * Strips any top-level ORDER BY before wrapping: ORDER BY is illegal
78
- * inside a derived table on SQL Server (unless TOP/OFFSET/FOR XML is
79
- * present), and the outer SELECT doesn't preserve inner ordering anyway.
80
- * The ORDER BY is moved to the outer SELECT so the final result retains
81
- * the intended sort order.
100
+ * Applies a row cap exactly as {@link WrapWithMaxRows} does, and also reports whether the cap
101
+ * holds and how, so a caller that asked for a cap can tell whether it got one.
82
102
  */
83
- private static outerWrap;
103
+ static ApplyMaxRows(resolvedSQL: string, maxRows: number, platform: DatabasePlatform): RowCapResult;
104
+ /** Caps a statement that has no cap of its own. */
105
+ private static addCap;
106
+ /** Lowers a numeric cap of the query's own to `cap`, or leaves it when it is already tighter. */
107
+ private static tightenCap;
108
+ /** How a row-limit suffix from the dialect's `LimitClause` caps rows: `FETCH` or `LIMIT`. */
109
+ private static suffixMethod;
84
110
  /**
85
- * AST-based row-cap injection.
86
- * `capped` — `sql` contains the input with TOP/LIMIT injected
87
- * or reduced to `min(existing, cap)`.
88
- * `wrap` — AST recognized the shape but the cap can't be
89
- * safely injected inline (`TOP PERCENT`, non-numeric
90
- * `TOP`/`LIMIT`); caller should outer-wrap.
91
- * `pass-through` — shape can't be capped at all without corrupting
92
- * the query (SELECT INTO, mutation).
93
- * `unparseable` — parser could not handle the input; caller may
94
- * attempt a CTE-fallback or outer wrap.
95
- *
96
- * All AST shape inspection is delegated to {@link SQLParser} primitives —
97
- * this method contains no `node-sql-parser` field knowledge.
111
+ * Caps the statement as a derived table, for shapes that cannot be capped in place. The
112
+ * query's CTEs stay in front and its trailing clause stays last. Its ORDER BY stays inside,
113
+ * where SQL Server allows it beside the query's own TOP; a set operation's ORDER BY, which
114
+ * names output columns, moves outside.
98
115
  */
99
- private static applyMaxRowsViaAST;
116
+ private static capAsDerivedTable;
100
117
  /**
101
- * Clauses that must come AFTER `LIMIT` in PostgreSQL, so a bare append would be illegal.
118
+ * Determines whether the given params indicate paging should be applied.
119
+ *
120
+ * A `MaxRows` on its own is enough — a caller asking only to cap a result, rather than
121
+ * to walk pages, still gets the ceiling applied in SQL. Without that, such a call falls
122
+ * through to the provider's full-fetch-then-slice path, where the database returns every
123
+ * row and the whole set crosses the network before being trimmed.
102
124
  *
103
- * Matched loosely and deliberately: a false positive (the word inside a string literal, a
104
- * column alias, or a nested subquery) costs only a fall-through to the AST path, which is
105
- * the behaviour that shipped before. A false negative would emit invalid SQL, so the test
106
- * errs heavily toward abstaining.
125
+ * Matches how RunView decides the same question (`BuildTotalRowCountSQL` treats rows as
126
+ * limited when `usingPagination || maxRowsForQuery > 0`).
127
+ *
128
+ * An absent `StartRow` means page zero; see {@link ResolveStartRow}. A negative one is
129
+ * rejected.
107
130
  */
108
- private static readonly CLAUSES_THAT_FOLLOW_LIMIT;
131
+ static ShouldPage(startRow: number | undefined, maxRows: number | undefined): boolean;
109
132
  /**
110
- * Returns `sql` with the row cap appended as a trailing clause, or `null` when that is not
111
- * provably safe and the caller should fall back to AST injection.
133
+ * The offset to page from: the caller's `StartRow`, or 0 when they named none.
112
134
  *
113
- * Applies only to dialects whose cap is a suffix (`LIMIT N`). SQL Server caps with a `TOP N`
114
- * prefix that has to go between `SELECT` and the select list — a position no append can
115
- * reach — so it is left to the AST path, where the round-trip is harmless anyway because
116
- * T-SQL is not case-sensitive about the identifiers involved.
135
+ * Kept beside {@link ShouldPage} so the two cannot drift — every site acting on a true
136
+ * `ShouldPage` needs a concrete offset, and `StartRow` is not guaranteed to be set.
117
137
  */
118
- private static appendTrailingCap;
138
+ static ResolveStartRow(startRow: number | undefined): number;
139
+ /** Removes trailing semicolons and whitespace; a statement-ending `;` cannot precede a paging clause. */
140
+ private static stripTrailingSemicolons;
119
141
  /**
120
- * Determines whether the given params indicate paging should be applied.
142
+ * Builds the SQL for one page. A query without a cap of its own gets the paging clause
143
+ * appended; a single numeric cap is replaced by the page's clause with the arithmetic folded
144
+ * in; anything else is paged as a derived table.
121
145
  */
122
- static ShouldPage(startRow: number | undefined, maxRows: number | undefined): boolean;
123
146
  private static buildDataSQL;
147
+ /** The statement up to the clause that must stay last. */
148
+ private static head;
149
+ /** The clause that must stay last (`OPTION (…)`, `FOR UPDATE`), with its leading newline, or ''. */
150
+ private static tail;
151
+ /** Appends ORDER BY (when the statement has none), the paging clause and the trailing clause. */
152
+ private static appendPage;
153
+ /**
154
+ * The ORDER BY to page by when the statement has none: the dialect's
155
+ * {@link SQLDialect.SelectListPagingOrderBy} for a set operation or SELECT DISTINCT when it
156
+ * has one (a platform that only accepts select-list items there), otherwise its
157
+ * {@link SQLDialect.DefaultPagingOrderBy}.
158
+ */
159
+ private static defaultOrderBy;
160
+ /**
161
+ * Pages within a numeric cap of the query's own: the page starts `startRow` rows into the
162
+ * capped result and stops at the cap. A page that starts at or past the cap is empty.
163
+ */
164
+ private static pageWithinCap;
124
165
  /**
125
- * Strips a TOP clause from the outermost SELECT statement.
126
- * Handles `TOP N` and `TOP (N)`, with or without DISTINCT.
127
- * Does not affect TOP in subqueries or CTEs.
166
+ * Pages a query whose own cap cannot be reasoned about as a row count (`TOP … PERCENT`, `WITH
167
+ * TIES`, an expression, or a cap on more than one branch of a set operation) by selecting the
168
+ * page from it as a derived table. Its CTEs stay in front, its trailing clause stays last, and
169
+ * the ORDER BY of a set operation moves outside, where it is legal.
128
170
  */
129
- private static stripTopFromMainSelect;
171
+ private static wrapAndPage;
172
+ /** A statement that returns no rows, for a page that starts past the query's own cap. */
173
+ private static emptyResultSQL;
130
174
  /**
131
- * Builds count SQL that wraps the (cap-free, ORDER-BY-free) query in a
132
- * `[__count]` CTE and selects `COUNT(*)`. A single instance-API path:
133
- * 1. `ExtractCTEs` hoists any user CTEs as siblings (a CTE body can't
134
- * contain its own WITH) — AST parse first, paren-depth regex fallback.
135
- * 2. `stripCountBody` removes the top-level ORDER BY (irrelevant for a
136
- * count, and illegal in a SQL Server CTE without TOP) and any outer
137
- * TOP / LIMIT (so the count reflects the full set, consistent with the
138
- * paged data query).
175
+ * Builds the count query: the main statement in a `[__count]` CTE placed after the query's
176
+ * own CTEs (a CTE body cannot contain its own WITH), and `SELECT COUNT(*) AS TotalRowCount`.
177
+ * The ORDER BY is removed — it does not change a count, and SQL Server forbids it in a CTE —
178
+ * unless the query's own cap needs it to choose its rows. A trailing `OPTION (…)` stays last.
139
179
  */
140
180
  private static buildCountSQL;
141
181
  /**
142
- * Strips the ORDER BY and any outer row cap (TOP on SQL Server, LIMIT on
143
- * PostgreSQL) from the statement being counted, via a single parser
144
- * round-trip — so the count reflects the full set rather than the capped
145
- * subset. Falls back to a string-based ORDER BY strip when the statement
146
- * can't be parsed (e.g. TRY_CAST, unresolved templates); the cap can't be
147
- * reliably removed without a parse, matching the prior regex behavior.
182
+ * The main statement as the count query sees it. With a cap of its own the statement is kept
183
+ * whole (its ORDER BY picks the capped rows, and is legal in a CTE beside TOP or OFFSET),
184
+ * except that a set operation's trailing ORDER BY is dropped; otherwise the ORDER BY is cut.
148
185
  */
149
- private static stripCountBody;
186
+ private static countBody;
150
187
  /**
151
188
  * Extracts the top-level ORDER BY clause from SQL, ignoring ORDER BY
152
189
  * inside subqueries, block comments, line comments, single-quoted strings,
@@ -165,11 +202,6 @@ export declare class QueryPagingEngine {
165
202
  sql: string;
166
203
  topRemoved: boolean;
167
204
  };
168
- /**
169
- * ExtractCTEs returns CTE definitions with unquoted names (e.g. `myName AS (...)`).
170
- * Apply dialect-specific identifier quoting to the CTE name.
171
- */
172
- private static quoteCteName;
173
205
  private static getDialect;
174
206
  }
175
207
  //# sourceMappingURL=queryPagingEngine.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"queryPagingEngine.d.ts","sourceRoot":"","sources":["../src/queryPagingEngine.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAC;AAExD,OAAO,EAAgC,KAAK,UAAU,EAAE,MAAM,6BAA6B,CAAC;AAE5F;;GAEG;AACH,MAAM,WAAW,gBAAgB;IAC7B,2CAA2C;IAC3C,OAAO,EAAE,MAAM,CAAC;IAChB,4DAA4D;IAC5D,QAAQ,EAAE,MAAM,CAAC;IACjB,mDAAmD;IACnD,MAAM,EAAE,MAAM,CAAC;IACf,4CAA4C;IAC5C,QAAQ,EAAE,MAAM,CAAC;CACpB;AAED;;;;;;;;;;;;;;;;GAgBG;AACH,qBAAa,iBAAiB;IAE1B;;;;;;;;OAQG;IACH,MAAM,CAAC,cAAc,CACjB,WAAW,EAAE,MAAM,EACnB,QAAQ,EAAE,MAAM,EAChB,OAAO,EAAE,MAAM,EACf,QAAQ,EAAE,gBAAgB,GAC3B,gBAAgB;IAUnB;;;;;;;;;;;;;;;;;;;;;;;;;OAyBG;IACH,MAAM,CAAC,eAAe,CAClB,WAAW,EAAE,MAAM,EACnB,OAAO,EAAE,MAAM,EACf,QAAQ,EAAE,gBAAgB,GAC3B,MAAM;IAsCT;;;;;;;;;;;OAWG;IACH,OAAO,CAAC,MAAM,CAAC,SAAS;IAyBxB;;;;;;;;;;;;;;OAcG;IACH,OAAO,CAAC,MAAM,CAAC,kBAAkB;IA2DjC;;;;;;;OAOG;IACH,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAC,yBAAyB,CACgC;IAEjF;;;;;;;;OAQG;IACH,OAAO,CAAC,MAAM,CAAC,iBAAiB;IAOhC;;OAEG;IACH,MAAM,CAAC,UAAU,CAAC,QAAQ,EAAE,MAAM,GAAG,SAAS,EAAE,OAAO,EAAE,MAAM,GAAG,SAAS,GAAG,OAA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