@askdb/sqlserver 0.1.0-beta.12 → 0.1.0-beta.14
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.
- package/README.md +30 -1
- package/dist/exec/sqlserver.d.ts +51 -3
- package/dist/exec/sqlserver.d.ts.map +1 -1
- package/dist/exec/sqlserver.js +155 -21
- package/dist/exec/sqlserver.js.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -53,7 +53,7 @@ const result = await introspect(
|
|
|
53
53
|
{
|
|
54
54
|
mode: "live",
|
|
55
55
|
runner: createSqlServerCatalogQueryRunner(
|
|
56
|
-
"Server=host,1433;Database=mydb;User Id=sa;Password=pass;",
|
|
56
|
+
"Server=host,1433;Database=mydb;User Id=sa;Password=pass;TrustServerCertificate=True;",
|
|
57
57
|
),
|
|
58
58
|
},
|
|
59
59
|
{ outDir: "./my-app.schema", schemaId: "my-app" },
|
|
@@ -61,6 +61,35 @@ const result = await introspect(
|
|
|
61
61
|
);
|
|
62
62
|
```
|
|
63
63
|
|
|
64
|
+
### Connection string formats
|
|
65
|
+
|
|
66
|
+
`createSqlServerCatalogQueryRunner` and `databaseUrl` in `askdb.config.ts` accept three formats:
|
|
67
|
+
|
|
68
|
+
| Format | Example |
|
|
69
|
+
|--------|---------|
|
|
70
|
+
| `mssql://` URL | `mssql://sa:pass@localhost:1433/MyDb` |
|
|
71
|
+
| Prisma `sqlserver://` | `sqlserver://localhost:1433;database=MyDb;user=sa;password=pass;encrypt=true` |
|
|
72
|
+
| ADO.NET (`Key=Value;`) | `Server=localhost,1433;Database=MyDb;User Id=sa;Password=pass;` |
|
|
73
|
+
|
|
74
|
+
**TLS / self-signed certificates**
|
|
75
|
+
|
|
76
|
+
SQL Server uses TLS by default. If you connect to a local or dev instance with a self-signed certificate you will see a `self-signed certificate` error unless you tell the driver to trust it:
|
|
77
|
+
|
|
78
|
+
- **`mssql://` URL** — append `?trustServerCertificate=true`:
|
|
79
|
+
```
|
|
80
|
+
mssql://sa:pass@localhost:1433/MyDb?trustServerCertificate=true
|
|
81
|
+
```
|
|
82
|
+
- **Prisma URL** — append `;trustServerCertificate=true`:
|
|
83
|
+
```
|
|
84
|
+
sqlserver://localhost:1433;database=MyDb;user=sa;password=pass;trustServerCertificate=true
|
|
85
|
+
```
|
|
86
|
+
- **ADO.NET string** — add `TrustServerCertificate=True;` (note: use the camelCase form without spaces — `Trust Server Certificate` with spaces is a known parsing gap in mssql v12):
|
|
87
|
+
```
|
|
88
|
+
Server=localhost,1433;Database=MyDb;User Id=sa;Password=pass;Encrypt=True;TrustServerCertificate=True;
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
> **Never set `TrustServerCertificate=True` in production** unless you have verified the server's certificate through another means. Use a properly signed certificate, or install the CA cert in the system trust store (`NODE_EXTRA_CA_CERTS` / `--use-system-ca`).
|
|
92
|
+
|
|
64
93
|
## Captured metadata
|
|
65
94
|
|
|
66
95
|
Tables, views, columns (SQL Server native type strings), primary keys, unique constraints, foreign keys (with referential actions), and indexes.
|
package/dist/exec/sqlserver.d.ts
CHANGED
|
@@ -1,11 +1,59 @@
|
|
|
1
1
|
import type { CatalogQueryRunner } from "@askdb/introspect";
|
|
2
2
|
export type { CatalogQueryResult, CatalogQueryRunner } from "@askdb/introspect";
|
|
3
|
+
type MssqlModule = typeof import("mssql");
|
|
4
|
+
/**
|
|
5
|
+
* Lazily resolve the optional `mssql` peer dependency. Mirrors the lazy-load
|
|
6
|
+
* pattern in `@askdb/postgres` / `@askdb/mysql` so consumers with a custom
|
|
7
|
+
* `CatalogQueryRunner` can import `@askdb/sqlserver` without `mssql` installed.
|
|
8
|
+
*/
|
|
9
|
+
type DriverLoadOptions = {
|
|
10
|
+
resolveFrom?: string;
|
|
11
|
+
};
|
|
3
12
|
/** @internal exposed for tests that need to reset the lazy `mssql` cache. */
|
|
4
13
|
export declare function __resetMssqlModuleCacheForTests(): void;
|
|
14
|
+
type MssqlDriverModule = MssqlModule;
|
|
15
|
+
/**
|
|
16
|
+
* Resolve and cache the optional `mssql` peer driver, with the same lazy-import
|
|
17
|
+
* + project-root fallback behavior as the catalog runner.
|
|
18
|
+
*/
|
|
19
|
+
export declare function loadMssqlDriver(options?: DriverLoadOptions): Promise<MssqlDriverModule>;
|
|
20
|
+
export declare function isMssqlDriverInstalled(options?: DriverLoadOptions): boolean;
|
|
21
|
+
export type MssqlConfigInput = {
|
|
22
|
+
server: string;
|
|
23
|
+
port?: number;
|
|
24
|
+
database?: string;
|
|
25
|
+
user?: string;
|
|
26
|
+
password?: string;
|
|
27
|
+
options?: {
|
|
28
|
+
encrypt?: boolean;
|
|
29
|
+
trustServerCertificate?: boolean;
|
|
30
|
+
};
|
|
31
|
+
};
|
|
32
|
+
/**
|
|
33
|
+
* mssql v12 uses @tediousjs/connection-string v1.x, which has two known gaps:
|
|
34
|
+
*
|
|
35
|
+
* 1. URL format (`mssql://…`, `sqlserver://…`) — the library is a pure ADO.NET
|
|
36
|
+
* key=value parser and silently produces an empty config, leaving `server`
|
|
37
|
+
* undefined. We detect these schemes and parse them into config objects.
|
|
38
|
+
*
|
|
39
|
+
* 2. ADO.NET multi-word keys with spaces — the library schema uses the no-space
|
|
40
|
+
* form (`trustservercertificate`) but ADO.NET client tools emit keys with
|
|
41
|
+
* spaces (`Trust Server Certificate`). After lowercasing by the parser these
|
|
42
|
+
* never match the schema, so options like TrustServerCertificate are silently
|
|
43
|
+
* dropped. We normalise the affected keys before passing the string to mssql.
|
|
44
|
+
*
|
|
45
|
+
* ADO.NET strings are identified as anything that is not a URL (no `://`).
|
|
46
|
+
*/
|
|
47
|
+
export declare function resolveConnectionInput(connectionString: string): string | MssqlConfigInput;
|
|
5
48
|
/**
|
|
6
49
|
* Build the built-in `mssql`-backed catalog query runner used by live SQL
|
|
7
|
-
* Server introspection.
|
|
8
|
-
*
|
|
50
|
+
* Server introspection. `connectionString` may be:
|
|
51
|
+
* - ADO.NET format: `Server=host,1433;Database=db;User Id=u;Password=p;`
|
|
52
|
+
* - `mssql://` URL: `mssql://user:pass@host:1433/database`
|
|
53
|
+
* - Prisma format: `sqlserver://host:1433;database=db;user=u;password=p`
|
|
54
|
+
*
|
|
55
|
+
* mssql v12+ only understands ADO.NET strings; URL formats are converted to a
|
|
56
|
+
* config object automatically.
|
|
9
57
|
*/
|
|
10
|
-
export declare function createSqlServerCatalogQueryRunner(connectionString: string): CatalogQueryRunner;
|
|
58
|
+
export declare function createSqlServerCatalogQueryRunner(connectionString: string, options?: DriverLoadOptions): CatalogQueryRunner;
|
|
11
59
|
//# sourceMappingURL=sqlserver.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sqlserver.d.ts","sourceRoot":"","sources":["../../src/exec/sqlserver.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAsB,kBAAkB,EAAE,MAAM,mBAAmB,CAAC;AAKhF,YAAY,EAAE,kBAAkB,EAAE,kBAAkB,EAAE,MAAM,mBAAmB,CAAC;
|
|
1
|
+
{"version":3,"file":"sqlserver.d.ts","sourceRoot":"","sources":["../../src/exec/sqlserver.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAsB,kBAAkB,EAAE,MAAM,mBAAmB,CAAC;AAKhF,YAAY,EAAE,kBAAkB,EAAE,kBAAkB,EAAE,MAAM,mBAAmB,CAAC;AAIhF,KAAK,WAAW,GAAG,cAAc,OAAO,CAAC,CAAC;AAE1C;;;;GAIG;AACH,KAAK,iBAAiB,GAAG;IAAE,WAAW,CAAC,EAAE,MAAM,CAAA;CAAE,CAAC;AAoDlD,6EAA6E;AAC7E,wBAAgB,+BAA+B,IAAI,IAAI,CAEtD;AAED,KAAK,iBAAiB,GAAG,WAAW,CAAC;AAErC;;;GAGG;AACH,wBAAsB,eAAe,CAAC,OAAO,CAAC,EAAE,iBAAiB,GAAG,OAAO,CAAC,iBAAiB,CAAC,CAG7F;AAED,wBAAgB,sBAAsB,CAAC,OAAO,CAAC,EAAE,iBAAiB,GAAG,OAAO,CAQ3E;AAED,MAAM,MAAM,gBAAgB,GAAG;IAC7B,MAAM,EAAE,MAAM,CAAC;IACf,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE;QAAE,OAAO,CAAC,EAAE,OAAO,CAAC;QAAC,sBAAsB,CAAC,EAAE,OAAO,CAAA;KAAE,CAAC;CACnE,CAAC;AAEF;;;;;;;;;;;;;;GAcG;AACH,wBAAgB,sBAAsB,CAAC,gBAAgB,EAAE,MAAM,GAAG,MAAM,GAAG,gBAAgB,CAa1F;AAgID;;;;;;;;;GASG;AACH,wBAAgB,iCAAiC,CAC/C,gBAAgB,EAAE,MAAM,EACxB,OAAO,CAAC,EAAE,iBAAiB,GAC1B,kBAAkB,CAEpB"}
|
package/dist/exec/sqlserver.js
CHANGED
|
@@ -2,12 +2,7 @@ import { AskDbError } from "@askdb/core";
|
|
|
2
2
|
import { createRequire } from "node:module";
|
|
3
3
|
import { join } from "node:path";
|
|
4
4
|
import { pathToFileURL } from "node:url";
|
|
5
|
-
|
|
6
|
-
* Lazily resolve the optional `mssql` peer dependency. Mirrors the lazy-load
|
|
7
|
-
* pattern in `@askdb/postgres` / `@askdb/mysql` so consumers with a custom
|
|
8
|
-
* `CatalogQueryRunner` can import `@askdb/sqlserver` without `mssql` installed.
|
|
9
|
-
*/
|
|
10
|
-
let mssqlModulePromise;
|
|
5
|
+
let mssqlModulePromises = new Map();
|
|
11
6
|
function isModuleResolutionFailure(cause, packageName) {
|
|
12
7
|
if (!(cause instanceof Error))
|
|
13
8
|
return false;
|
|
@@ -20,14 +15,15 @@ function isModuleResolutionFailure(cause, packageName) {
|
|
|
20
15
|
return false;
|
|
21
16
|
return cause.message.includes(packageName);
|
|
22
17
|
}
|
|
23
|
-
async function importOptionalMssql() {
|
|
18
|
+
async function importOptionalMssql(opts) {
|
|
24
19
|
try {
|
|
25
20
|
return await import("mssql");
|
|
26
21
|
}
|
|
27
22
|
catch (cause) {
|
|
28
23
|
if (!isModuleResolutionFailure(cause, "mssql"))
|
|
29
24
|
throw cause;
|
|
30
|
-
const
|
|
25
|
+
const fromDir = opts?.resolveFrom ?? process.cwd();
|
|
26
|
+
const projectRequire = createRequire(join(fromDir, "package.json"));
|
|
31
27
|
try {
|
|
32
28
|
const resolved = projectRequire.resolve("mssql");
|
|
33
29
|
return (await import(pathToFileURL(resolved).href));
|
|
@@ -39,26 +35,159 @@ async function importOptionalMssql() {
|
|
|
39
35
|
}
|
|
40
36
|
}
|
|
41
37
|
}
|
|
42
|
-
async function loadMssqlOrThrow() {
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
38
|
+
async function loadMssqlOrThrow(opts) {
|
|
39
|
+
const key = opts?.resolveFrom;
|
|
40
|
+
let promise = mssqlModulePromises.get(key);
|
|
41
|
+
if (!promise) {
|
|
42
|
+
promise = importOptionalMssql(opts).catch((cause) => {
|
|
43
|
+
mssqlModulePromises.delete(key);
|
|
46
44
|
throw new AskDbError("The built-in SQL Server catalog query runner requires the optional `mssql` peer dependency. " +
|
|
47
45
|
"Install it in your project (e.g. `pnpm add mssql`) or include it in the same one-off command " +
|
|
48
46
|
"(e.g. `pnpm dlx -p askdb -p mssql askdb ...` or `npx -p askdb -p mssql askdb ...`). " +
|
|
49
47
|
"You can also pass a custom catalog query runner to the SQL Server connector.", cause);
|
|
50
48
|
});
|
|
49
|
+
mssqlModulePromises.set(key, promise);
|
|
51
50
|
}
|
|
52
|
-
return
|
|
51
|
+
return promise;
|
|
53
52
|
}
|
|
54
53
|
/** @internal exposed for tests that need to reset the lazy `mssql` cache. */
|
|
55
54
|
export function __resetMssqlModuleCacheForTests() {
|
|
56
|
-
|
|
55
|
+
mssqlModulePromises.clear();
|
|
56
|
+
}
|
|
57
|
+
/**
|
|
58
|
+
* Resolve and cache the optional `mssql` peer driver, with the same lazy-import
|
|
59
|
+
* + project-root fallback behavior as the catalog runner.
|
|
60
|
+
*/
|
|
61
|
+
export async function loadMssqlDriver(options) {
|
|
62
|
+
const mod = await loadMssqlOrThrow(options);
|
|
63
|
+
return mod.default ?? mod;
|
|
64
|
+
}
|
|
65
|
+
export function isMssqlDriverInstalled(options) {
|
|
66
|
+
try {
|
|
67
|
+
const req = createRequire(join(options?.resolveFrom ?? process.cwd(), "package.json"));
|
|
68
|
+
req.resolve("mssql");
|
|
69
|
+
return true;
|
|
70
|
+
}
|
|
71
|
+
catch {
|
|
72
|
+
return false;
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
/**
|
|
76
|
+
* mssql v12 uses @tediousjs/connection-string v1.x, which has two known gaps:
|
|
77
|
+
*
|
|
78
|
+
* 1. URL format (`mssql://…`, `sqlserver://…`) — the library is a pure ADO.NET
|
|
79
|
+
* key=value parser and silently produces an empty config, leaving `server`
|
|
80
|
+
* undefined. We detect these schemes and parse them into config objects.
|
|
81
|
+
*
|
|
82
|
+
* 2. ADO.NET multi-word keys with spaces — the library schema uses the no-space
|
|
83
|
+
* form (`trustservercertificate`) but ADO.NET client tools emit keys with
|
|
84
|
+
* spaces (`Trust Server Certificate`). After lowercasing by the parser these
|
|
85
|
+
* never match the schema, so options like TrustServerCertificate are silently
|
|
86
|
+
* dropped. We normalise the affected keys before passing the string to mssql.
|
|
87
|
+
*
|
|
88
|
+
* ADO.NET strings are identified as anything that is not a URL (no `://`).
|
|
89
|
+
*/
|
|
90
|
+
export function resolveConnectionInput(connectionString) {
|
|
91
|
+
if (connectionString.startsWith("mssql://")) {
|
|
92
|
+
return parseMssqlSchemeUrl(connectionString);
|
|
93
|
+
}
|
|
94
|
+
if (connectionString.startsWith("sqlserver://")) {
|
|
95
|
+
return parsePrismaSqlServerUrl(connectionString);
|
|
96
|
+
}
|
|
97
|
+
// ADO.NET string: normalise multi-word keys that @tediousjs/connection-string
|
|
98
|
+
// v1.x does not recognise in their spaced form.
|
|
99
|
+
if (!connectionString.includes("://")) {
|
|
100
|
+
return normalizeAdoNetString(connectionString);
|
|
101
|
+
}
|
|
102
|
+
return connectionString;
|
|
103
|
+
}
|
|
104
|
+
/**
|
|
105
|
+
* @tediousjs/connection-string v1.x schema uses camelCase/no-space forms as
|
|
106
|
+
* keys, but ADO.NET clients (VS Code mssql, SSMS) emit the space-separated
|
|
107
|
+
* forms. Map each affected key to the form the schema actually recognises.
|
|
108
|
+
*/
|
|
109
|
+
const ADO_NET_KEY_NORMALISATIONS = [
|
|
110
|
+
[/Trust\s+Server\s+Certificate\s*=/gi, "TrustServerCertificate="],
|
|
111
|
+
[/Application\s+Intent\s*=/gi, "ApplicationIntent="],
|
|
112
|
+
[/Multiple\s+Active\s+Result\s+Sets\s*=/gi, "MultipleActiveResultSets="],
|
|
113
|
+
[/Connect\s+Retry\s+Count\s*=/gi, "ConnectRetryCount="],
|
|
114
|
+
[/Connect\s+Retry\s+Interval\s*=/gi, "ConnectRetryInterval="],
|
|
115
|
+
[/Transparent\s+Network\s+IP\s+Resolution\s*=/gi, "TransparentNetworkIpResolution="],
|
|
116
|
+
];
|
|
117
|
+
function normalizeAdoNetString(connectionString) {
|
|
118
|
+
let result = connectionString;
|
|
119
|
+
for (const [pattern, replacement] of ADO_NET_KEY_NORMALISATIONS) {
|
|
120
|
+
result = result.replace(pattern, replacement);
|
|
121
|
+
}
|
|
122
|
+
return result;
|
|
123
|
+
}
|
|
124
|
+
function parseMssqlSchemeUrl(connectionString) {
|
|
125
|
+
const url = new URL(connectionString);
|
|
126
|
+
const server = url.hostname;
|
|
127
|
+
if (!server) {
|
|
128
|
+
throw new AskDbError("Cannot parse server hostname from SQL Server connection URL. " +
|
|
129
|
+
"Expected format: mssql://USER:PASSWORD@HOST:PORT/DATABASE");
|
|
130
|
+
}
|
|
131
|
+
const port = url.port ? parseInt(url.port, 10) : undefined;
|
|
132
|
+
const database = url.pathname.length > 1 ? url.pathname.slice(1) : undefined;
|
|
133
|
+
const user = url.username ? decodeURIComponent(url.username) : undefined;
|
|
134
|
+
const password = url.password ? decodeURIComponent(url.password) : undefined;
|
|
135
|
+
const encrypt = url.searchParams.get("encrypt");
|
|
136
|
+
const trustCert = url.searchParams.get("trustServerCertificate") ?? url.searchParams.get("TrustServerCertificate");
|
|
137
|
+
return {
|
|
138
|
+
server,
|
|
139
|
+
...(port !== undefined && !Number.isNaN(port) ? { port } : {}),
|
|
140
|
+
...(database ? { database } : {}),
|
|
141
|
+
...(user ? { user } : {}),
|
|
142
|
+
...(password ? { password } : {}),
|
|
143
|
+
options: {
|
|
144
|
+
...(encrypt !== null ? { encrypt: !["false", "0", "no"].includes(encrypt.toLowerCase()) } : {}),
|
|
145
|
+
...(trustCert !== null ? { trustServerCertificate: !["false", "0", "no"].includes(trustCert.toLowerCase()) } : {}),
|
|
146
|
+
},
|
|
147
|
+
};
|
|
148
|
+
}
|
|
149
|
+
function parsePrismaSqlServerUrl(connectionString) {
|
|
150
|
+
// Prisma format: sqlserver://HOST:PORT;database=DATABASE;user=USER;password=PASSWORD;encrypt=true
|
|
151
|
+
const withoutScheme = connectionString.slice("sqlserver://".length);
|
|
152
|
+
const firstSemiIdx = withoutScheme.indexOf(";");
|
|
153
|
+
const hostPart = firstSemiIdx === -1 ? withoutScheme : withoutScheme.slice(0, firstSemiIdx);
|
|
154
|
+
const paramsPart = firstSemiIdx === -1 ? "" : withoutScheme.slice(firstSemiIdx + 1);
|
|
155
|
+
const colonIdx = hostPart.lastIndexOf(":");
|
|
156
|
+
const server = colonIdx === -1 ? hostPart : hostPart.slice(0, colonIdx);
|
|
157
|
+
const portStr = colonIdx === -1 ? undefined : hostPart.slice(colonIdx + 1);
|
|
158
|
+
const port = portStr ? parseInt(portStr, 10) : undefined;
|
|
159
|
+
if (!server) {
|
|
160
|
+
throw new AskDbError("Cannot parse server hostname from Prisma-style SQL Server URL. " +
|
|
161
|
+
"Expected: sqlserver://HOST:PORT;database=DATABASE;user=USER;password=PASSWORD");
|
|
162
|
+
}
|
|
163
|
+
const params = {};
|
|
164
|
+
for (const part of paramsPart.split(";")) {
|
|
165
|
+
const eqIdx = part.indexOf("=");
|
|
166
|
+
if (eqIdx === -1)
|
|
167
|
+
continue;
|
|
168
|
+
const key = part.slice(0, eqIdx).trim().toLowerCase();
|
|
169
|
+
const value = part.slice(eqIdx + 1).trim();
|
|
170
|
+
if (key && value)
|
|
171
|
+
params[key] = value;
|
|
172
|
+
}
|
|
173
|
+
return {
|
|
174
|
+
server,
|
|
175
|
+
...(port !== undefined && !Number.isNaN(port) ? { port } : {}),
|
|
176
|
+
...(params["database"] ? { database: params["database"] } : {}),
|
|
177
|
+
...(params["user"] ? { user: params["user"] } : {}),
|
|
178
|
+
...(params["password"] ? { password: params["password"] } : {}),
|
|
179
|
+
options: {
|
|
180
|
+
...(params["encrypt"] !== undefined ? { encrypt: params["encrypt"].toLowerCase() === "true" } : {}),
|
|
181
|
+
...(params["trustservercertificate"] !== undefined
|
|
182
|
+
? { trustServerCertificate: params["trustservercertificate"].toLowerCase() === "true" }
|
|
183
|
+
: {}),
|
|
184
|
+
},
|
|
185
|
+
};
|
|
57
186
|
}
|
|
58
|
-
async function runSqlServerCatalogQuery(connectionString, sql, params) {
|
|
59
|
-
const mod = await loadMssqlOrThrow();
|
|
187
|
+
async function runSqlServerCatalogQuery(connectionString, sql, params, options) {
|
|
188
|
+
const mod = await loadMssqlOrThrow(options);
|
|
60
189
|
const mssql = mod.default ?? mod;
|
|
61
|
-
const pool = new mssql.ConnectionPool(connectionString);
|
|
190
|
+
const pool = new mssql.ConnectionPool(resolveConnectionInput(connectionString));
|
|
62
191
|
await pool.connect();
|
|
63
192
|
try {
|
|
64
193
|
const request = pool.request();
|
|
@@ -87,10 +216,15 @@ async function runSqlServerCatalogQuery(connectionString, sql, params) {
|
|
|
87
216
|
}
|
|
88
217
|
/**
|
|
89
218
|
* Build the built-in `mssql`-backed catalog query runner used by live SQL
|
|
90
|
-
* Server introspection.
|
|
91
|
-
*
|
|
219
|
+
* Server introspection. `connectionString` may be:
|
|
220
|
+
* - ADO.NET format: `Server=host,1433;Database=db;User Id=u;Password=p;`
|
|
221
|
+
* - `mssql://` URL: `mssql://user:pass@host:1433/database`
|
|
222
|
+
* - Prisma format: `sqlserver://host:1433;database=db;user=u;password=p`
|
|
223
|
+
*
|
|
224
|
+
* mssql v12+ only understands ADO.NET strings; URL formats are converted to a
|
|
225
|
+
* config object automatically.
|
|
92
226
|
*/
|
|
93
|
-
export function createSqlServerCatalogQueryRunner(connectionString) {
|
|
94
|
-
return (sql, params) => runSqlServerCatalogQuery(connectionString, sql, params);
|
|
227
|
+
export function createSqlServerCatalogQueryRunner(connectionString, options) {
|
|
228
|
+
return (sql, params) => runSqlServerCatalogQuery(connectionString, sql, params, options);
|
|
95
229
|
}
|
|
96
230
|
//# sourceMappingURL=sqlserver.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sqlserver.js","sourceRoot":"","sources":["../../src/exec/sqlserver.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAEzC,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAC5C,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AACjC,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;
|
|
1
|
+
{"version":3,"file":"sqlserver.js","sourceRoot":"","sources":["../../src/exec/sqlserver.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAEzC,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAC5C,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AACjC,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAezC,IAAI,mBAAmB,GAAG,IAAI,GAA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AC;IACrB,CAAC;AACH,CAAC;AAED;;;;;;;;;GASG;AACH,MAAM,UAAU,iCAAiC,CAC/C,gBAAwB,EACxB,OAA2B;IAE3B,OAAO,CAAC,GAAG,EAAE,MAAM,EAAE,EAAE,CAAC,wBAAwB,CAAC,gBAAgB,EAAE,GAAG,EAAE,MAAM,EAAE,OAAO,CAAC,CAAC;AAC3F,CAAC"}
|
package/dist/index.d.ts
CHANGED
|
@@ -7,6 +7,6 @@
|
|
|
7
7
|
*/
|
|
8
8
|
export { SQLSERVER_DIALECT, type DialectSpec as SqlServerDialect, } from "@askdb/core";
|
|
9
9
|
export { createSqlServerConnector, describeSqlServer, SQLSERVER_CATALOG_SQL, type DescribeSqlServerInput, type SqlServerIntrospectionInput, } from "./connector/index.js";
|
|
10
|
-
export { createSqlServerCatalogQueryRunner, type CatalogQueryResult, type CatalogQueryRunner, } from "./exec/sqlserver.js";
|
|
10
|
+
export { createSqlServerCatalogQueryRunner, loadMssqlDriver, isMssqlDriverInstalled, resolveConnectionInput, type CatalogQueryResult, type CatalogQueryRunner, type MssqlConfigInput, } from "./exec/sqlserver.js";
|
|
11
11
|
export { sqlServerConnectorProvider } from "./connector/provider.js";
|
|
12
12
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EACL,iBAAiB,EACjB,KAAK,WAAW,IAAI,gBAAgB,GACrC,MAAM,aAAa,CAAC;AAErB,OAAO,EACL,wBAAwB,EACxB,iBAAiB,EACjB,qBAAqB,EACrB,KAAK,sBAAsB,EAC3B,KAAK,2BAA2B,GACjC,MAAM,sBAAsB,CAAC;AAE9B,OAAO,EACL,iCAAiC,EACjC,KAAK,kBAAkB,EACvB,KAAK,kBAAkB,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EACL,iBAAiB,EACjB,KAAK,WAAW,IAAI,gBAAgB,GACrC,MAAM,aAAa,CAAC;AAErB,OAAO,EACL,wBAAwB,EACxB,iBAAiB,EACjB,qBAAqB,EACrB,KAAK,sBAAsB,EAC3B,KAAK,2BAA2B,GACjC,MAAM,sBAAsB,CAAC;AAE9B,OAAO,EACL,iCAAiC,EACjC,eAAe,EACf,sBAAsB,EACtB,sBAAsB,EACtB,KAAK,kBAAkB,EACvB,KAAK,kBAAkB,EACvB,KAAK,gBAAgB,GACtB,MAAM,qBAAqB,CAAC;AAE7B,OAAO,EAAE,0BAA0B,EAAE,MAAM,yBAAyB,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -7,6 +7,6 @@
|
|
|
7
7
|
*/
|
|
8
8
|
export { SQLSERVER_DIALECT, } from "@askdb/core";
|
|
9
9
|
export { createSqlServerConnector, describeSqlServer, SQLSERVER_CATALOG_SQL, } from "./connector/index.js";
|
|
10
|
-
export { createSqlServerCatalogQueryRunner, } from "./exec/sqlserver.js";
|
|
10
|
+
export { createSqlServerCatalogQueryRunner, loadMssqlDriver, isMssqlDriverInstalled, resolveConnectionInput, } from "./exec/sqlserver.js";
|
|
11
11
|
export { sqlServerConnectorProvider } from "./connector/provider.js";
|
|
12
12
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EACL,iBAAiB,GAElB,MAAM,aAAa,CAAC;AAErB,OAAO,EACL,wBAAwB,EACxB,iBAAiB,EACjB,qBAAqB,GAGtB,MAAM,sBAAsB,CAAC;AAE9B,OAAO,EACL,iCAAiC,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EACL,iBAAiB,GAElB,MAAM,aAAa,CAAC;AAErB,OAAO,EACL,wBAAwB,EACxB,iBAAiB,EACjB,qBAAqB,GAGtB,MAAM,sBAAsB,CAAC;AAE9B,OAAO,EACL,iCAAiC,EACjC,eAAe,EACf,sBAAsB,EACtB,sBAAsB,GAIvB,MAAM,qBAAqB,CAAC;AAE7B,OAAO,EAAE,0BAA0B,EAAE,MAAM,yBAAyB,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@askdb/sqlserver",
|
|
3
|
-
"version": "0.1.0-beta.
|
|
3
|
+
"version": "0.1.0-beta.14",
|
|
4
4
|
"description": "AskDB Microsoft SQL Server integration: introspection connector via sys.* catalog views and an mssql-backed catalog query runner. Pairs with @askdb/core's SQLSERVER_DIALECT.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"askdb",
|