drizzle-kit 0.22.0-29f7626 → 0.22.0-3c62a84
Sign up to get free protection for your applications and to get access to all the features.
- package/bin.cjs +137 -31
- package/package.json +1 -1
- package/payload.d.mts +100 -18
- package/payload.d.ts +100 -18
- package/payload.js +124 -27
- package/payload.mjs +124 -27
- package/utils-studio.js +24 -3
- package/utils-studio.mjs +24 -3
- package/utils.js +23 -2
- package/utils.mjs +23 -2
package/bin.cjs
CHANGED
@@ -5477,7 +5477,16 @@ var init_mysqlSchema = __esm({
|
|
5477
5477
|
objectType({ isDefaultAnExpression: booleanType().optional() }).optional()
|
5478
5478
|
)
|
5479
5479
|
}).optional()
|
5480
|
-
)
|
5480
|
+
).optional(),
|
5481
|
+
indexes: recordType(
|
5482
|
+
stringType(),
|
5483
|
+
objectType({
|
5484
|
+
columns: recordType(
|
5485
|
+
stringType(),
|
5486
|
+
objectType({ isExpression: booleanType().optional() }).optional()
|
5487
|
+
)
|
5488
|
+
}).optional()
|
5489
|
+
).optional()
|
5481
5490
|
}).optional();
|
5482
5491
|
dialect = literalType("mysql");
|
5483
5492
|
schemaHash = objectType({
|
@@ -6142,7 +6151,7 @@ var init_pgSchema = __esm({
|
|
6142
6151
|
});
|
6143
6152
|
|
6144
6153
|
// src/serializer/sqliteSchema.ts
|
6145
|
-
var index3, fk3, compositePK3, column3, tableV33, uniqueConstraint3, table3, dialect2, schemaHash3, schemaInternalV32, schemaInternalV42, schemaInternalV52, latestVersion, schemaInternal2, schemaV32, schemaV42, schemaV52, schema3, tableSquashed3, schemaSquashed2, SQLiteSquasher, squashSqliteScheme, drySQLite, sqliteSchemaV5, sqliteSchema, SQLiteSchemaSquashed, backwardCompatibleSqliteSchema;
|
6154
|
+
var index3, fk3, compositePK3, column3, tableV33, uniqueConstraint3, table3, dialect2, schemaHash3, schemaInternalV32, schemaInternalV42, schemaInternalV52, kitInternals3, latestVersion, schemaInternal2, schemaV32, schemaV42, schemaV52, schema3, tableSquashed3, schemaSquashed2, SQLiteSquasher, squashSqliteScheme, drySQLite, sqliteSchemaV5, sqliteSchema, SQLiteSchemaSquashed, backwardCompatibleSqliteSchema;
|
6146
6155
|
var init_sqliteSchema = __esm({
|
6147
6156
|
"src/serializer/sqliteSchema.ts"() {
|
6148
6157
|
"use strict";
|
@@ -6220,6 +6229,17 @@ var init_sqliteSchema = __esm({
|
|
6220
6229
|
columns: recordType(stringType(), stringType())
|
6221
6230
|
})
|
6222
6231
|
}).strict();
|
6232
|
+
kitInternals3 = objectType({
|
6233
|
+
indexes: recordType(
|
6234
|
+
stringType(),
|
6235
|
+
objectType({
|
6236
|
+
columns: recordType(
|
6237
|
+
stringType(),
|
6238
|
+
objectType({ isExpression: booleanType().optional() }).optional()
|
6239
|
+
)
|
6240
|
+
}).optional()
|
6241
|
+
).optional()
|
6242
|
+
}).optional();
|
6223
6243
|
latestVersion = literalType("6");
|
6224
6244
|
schemaInternal2 = objectType({
|
6225
6245
|
version: latestVersion,
|
@@ -6229,7 +6249,8 @@ var init_sqliteSchema = __esm({
|
|
6229
6249
|
_meta: objectType({
|
6230
6250
|
tables: recordType(stringType(), stringType()),
|
6231
6251
|
columns: recordType(stringType(), stringType())
|
6232
|
-
})
|
6252
|
+
}),
|
6253
|
+
internal: kitInternals3
|
6233
6254
|
}).strict();
|
6234
6255
|
schemaV32 = schemaInternalV32.merge(schemaHash3).strict();
|
6235
6256
|
schemaV42 = schemaInternalV42.merge(schemaHash3).strict();
|
@@ -15268,6 +15289,7 @@ var init_mysqlSerializer = __esm({
|
|
15268
15289
|
};
|
15269
15290
|
generateMySqlSnapshot = (tables) => {
|
15270
15291
|
const result = {};
|
15292
|
+
const internal = { tables: {}, indexes: {} };
|
15271
15293
|
for (const table4 of tables) {
|
15272
15294
|
const {
|
15273
15295
|
name: tableName,
|
@@ -15418,10 +15440,29 @@ The unique constraint ${source_default.underline.blue(
|
|
15418
15440
|
const columns2 = value.config.columns;
|
15419
15441
|
const name = value.config.name;
|
15420
15442
|
let indexColumns = columns2.map((it) => {
|
15443
|
+
var _a;
|
15421
15444
|
if ((0, import_drizzle_orm2.is)(it, import_drizzle_orm3.SQL)) {
|
15422
|
-
|
15445
|
+
const sql2 = dialect4.sqlToQuery(it, "indexes").sql;
|
15446
|
+
if (typeof internal.indexes[name] === "undefined") {
|
15447
|
+
internal.indexes[name] = {
|
15448
|
+
columns: {
|
15449
|
+
[sql2]: {
|
15450
|
+
isExpression: true
|
15451
|
+
}
|
15452
|
+
}
|
15453
|
+
};
|
15454
|
+
} else {
|
15455
|
+
if (typeof ((_a = internal.indexes[name]) == null ? void 0 : _a.columns[sql2]) === "undefined") {
|
15456
|
+
internal.indexes[name].columns[sql2] = {
|
15457
|
+
isExpression: true
|
15458
|
+
};
|
15459
|
+
} else {
|
15460
|
+
internal.indexes[name].columns[sql2].isExpression = true;
|
15461
|
+
}
|
15462
|
+
}
|
15463
|
+
return sql2;
|
15423
15464
|
} else {
|
15424
|
-
return it.name
|
15465
|
+
return `${it.name}`;
|
15425
15466
|
}
|
15426
15467
|
});
|
15427
15468
|
if (value.config.unique) {
|
@@ -15488,12 +15529,13 @@ We have encountered a collision between the index name on columns ${source_defau
|
|
15488
15529
|
_meta: {
|
15489
15530
|
tables: {},
|
15490
15531
|
columns: {}
|
15491
|
-
}
|
15532
|
+
},
|
15533
|
+
internal
|
15492
15534
|
};
|
15493
15535
|
};
|
15494
15536
|
fromDatabase = async (db2, inputSchema, tablesFilter = (table4) => true, progressCallback) => {
|
15495
15537
|
const result = {};
|
15496
|
-
const internals = { tables: {} };
|
15538
|
+
const internals = { tables: {}, indexes: {} };
|
15497
15539
|
const columns = await db2.query(`select * from information_schema.columns
|
15498
15540
|
where table_schema = '${inputSchema}' and table_name != '__drizzle_migrations'
|
15499
15541
|
order by table_name, ordinal_position;`);
|
@@ -16708,6 +16750,7 @@ var init_sqliteSerializer = __esm({
|
|
16708
16750
|
dialect6 = new import_sqlite_core2.SQLiteSyncDialect();
|
16709
16751
|
generateSqliteSnapshot = (tables) => {
|
16710
16752
|
const result = {};
|
16753
|
+
const internal = { indexes: {} };
|
16711
16754
|
for (const table4 of tables) {
|
16712
16755
|
const columnsObject = {};
|
16713
16756
|
const indexesObject = {};
|
@@ -16793,8 +16836,27 @@ ${withStyle.errorWarning(`We've found duplicated unique constraint names in ${so
|
|
16793
16836
|
const columns2 = value.config.columns;
|
16794
16837
|
const name = value.config.name;
|
16795
16838
|
let indexColumns = columns2.map((it) => {
|
16839
|
+
var _a;
|
16796
16840
|
if ((0, import_drizzle_orm7.is)(it, import_drizzle_orm7.SQL)) {
|
16797
|
-
|
16841
|
+
const sql2 = dialect6.sqlToQuery(it, "indexes").sql;
|
16842
|
+
if (typeof internal.indexes[name] === "undefined") {
|
16843
|
+
internal.indexes[name] = {
|
16844
|
+
columns: {
|
16845
|
+
[sql2]: {
|
16846
|
+
isExpression: true
|
16847
|
+
}
|
16848
|
+
}
|
16849
|
+
};
|
16850
|
+
} else {
|
16851
|
+
if (typeof ((_a = internal.indexes[name]) == null ? void 0 : _a.columns[sql2]) === "undefined") {
|
16852
|
+
internal.indexes[name].columns[sql2] = {
|
16853
|
+
isExpression: true
|
16854
|
+
};
|
16855
|
+
} else {
|
16856
|
+
internal.indexes[name].columns[sql2].isExpression = true;
|
16857
|
+
}
|
16858
|
+
}
|
16859
|
+
return sql2;
|
16798
16860
|
} else {
|
16799
16861
|
return it.name;
|
16800
16862
|
}
|
@@ -16868,7 +16930,8 @@ The unique constraint ${source_default.underline.blue(
|
|
16868
16930
|
_meta: {
|
16869
16931
|
tables: {},
|
16870
16932
|
columns: {}
|
16871
|
-
}
|
16933
|
+
},
|
16934
|
+
internal
|
16872
16935
|
};
|
16873
16936
|
};
|
16874
16937
|
fromDatabase3 = async (db2, tablesFilter = (table4) => true, progressCallback) => {
|
@@ -17371,7 +17434,14 @@ var init_sqlgenerator = __esm({
|
|
17371
17434
|
return statement.type === "create_table" && dialect7 === "mysql";
|
17372
17435
|
}
|
17373
17436
|
convert(st) {
|
17374
|
-
const {
|
17437
|
+
const {
|
17438
|
+
tableName,
|
17439
|
+
columns,
|
17440
|
+
schema: schema5,
|
17441
|
+
compositePKs,
|
17442
|
+
uniqueConstraints,
|
17443
|
+
internals
|
17444
|
+
} = st;
|
17375
17445
|
let statement = "";
|
17376
17446
|
statement += `CREATE TABLE \`${tableName}\` (
|
17377
17447
|
`;
|
@@ -17394,7 +17464,11 @@ var init_sqlgenerator = __esm({
|
|
17394
17464
|
for (const uniqueConstraint4 of uniqueConstraints) {
|
17395
17465
|
statement += ",\n";
|
17396
17466
|
const unsquashedUnique = MySqlSquasher.unsquashUnique(uniqueConstraint4);
|
17397
|
-
|
17467
|
+
const uniqueString = unsquashedUnique.columns.map((it) => {
|
17468
|
+
var _a, _b;
|
17469
|
+
return (internals == null ? void 0 : internals.indexes) ? ((_b = (_a = internals == null ? void 0 : internals.indexes[unsquashedUnique.name]) == null ? void 0 : _a.columns[it]) == null ? void 0 : _b.isExpression) ? it : `\`${it}\`` : `\`${it}\``;
|
17470
|
+
}).join(",");
|
17471
|
+
statement += ` CONSTRAINT \`${unsquashedUnique.name}\` UNIQUE(${uniqueString})`;
|
17398
17472
|
}
|
17399
17473
|
}
|
17400
17474
|
statement += `
|
@@ -18323,8 +18397,11 @@ ${BREAKPOINT}ALTER TABLE ${tableNameWithSchema} ADD CONSTRAINT ${statement.newCo
|
|
18323
18397
|
statement.data
|
18324
18398
|
);
|
18325
18399
|
const indexPart = isUnique ? "UNIQUE INDEX" : "INDEX";
|
18326
|
-
const
|
18327
|
-
|
18400
|
+
const uniqueString = columns.map((it) => {
|
18401
|
+
var _a, _b, _c, _d;
|
18402
|
+
return ((_a = statement.internal) == null ? void 0 : _a.indexes) ? ((_d = (_c = (_b = statement.internal) == null ? void 0 : _b.indexes[name]) == null ? void 0 : _c.columns[it]) == null ? void 0 : _d.isExpression) ? it : `\`${it}\`` : `\`${it}\``;
|
18403
|
+
}).join(",");
|
18404
|
+
return `CREATE ${indexPart} \`${name}\` ON \`${statement.tableName}\` (${uniqueString});`;
|
18328
18405
|
}
|
18329
18406
|
};
|
18330
18407
|
CreateSqliteIndexConvertor = class extends Convertor {
|
@@ -18337,8 +18414,11 @@ ${BREAKPOINT}ALTER TABLE ${tableNameWithSchema} ADD CONSTRAINT ${statement.newCo
|
|
18337
18414
|
);
|
18338
18415
|
const indexPart = isUnique ? "UNIQUE INDEX" : "INDEX";
|
18339
18416
|
const whereStatement = where ? ` WHERE ${where}` : "";
|
18340
|
-
const
|
18341
|
-
|
18417
|
+
const uniqueString = columns.map((it) => {
|
18418
|
+
var _a, _b, _c, _d;
|
18419
|
+
return ((_a = statement.internal) == null ? void 0 : _a.indexes) ? ((_d = (_c = (_b = statement.internal) == null ? void 0 : _b.indexes[name]) == null ? void 0 : _c.columns[it]) == null ? void 0 : _d.isExpression) ? it : `\`${it}\`` : `\`${it}\``;
|
18420
|
+
}).join(",");
|
18421
|
+
return `CREATE ${indexPart} \`${name}\` ON \`${statement.tableName}\` (${uniqueString})${whereStatement};`;
|
18342
18422
|
}
|
18343
18423
|
};
|
18344
18424
|
PgDropIndexConvertor = class extends Convertor {
|
@@ -18986,7 +19066,7 @@ var init_jsonStatements = __esm({
|
|
18986
19066
|
uniqueConstraints: Object.values(uniqueConstraints)
|
18987
19067
|
};
|
18988
19068
|
};
|
18989
|
-
prepareMySqlCreateTableJson = (table4, json2) => {
|
19069
|
+
prepareMySqlCreateTableJson = (table4, json2, internals) => {
|
18990
19070
|
const { name, schema: schema5, columns, compositePrimaryKeys, uniqueConstraints } = table4;
|
18991
19071
|
return {
|
18992
19072
|
type: "create_table",
|
@@ -18995,7 +19075,8 @@ var init_jsonStatements = __esm({
|
|
18995
19075
|
columns: Object.values(columns),
|
18996
19076
|
compositePKs: Object.values(compositePrimaryKeys),
|
18997
19077
|
compositePkName: Object.values(compositePrimaryKeys).length > 0 ? json2.tables[name].compositePrimaryKeys[MySqlSquasher.unsquashPK(Object.values(compositePrimaryKeys)[0]).name].name : "",
|
18998
|
-
uniqueConstraints: Object.values(uniqueConstraints)
|
19078
|
+
uniqueConstraints: Object.values(uniqueConstraints),
|
19079
|
+
internals
|
18999
19080
|
};
|
19000
19081
|
};
|
19001
19082
|
prepareSQLiteCreateTable = (table4) => {
|
@@ -19752,13 +19833,14 @@ var init_jsonStatements = __esm({
|
|
19752
19833
|
};
|
19753
19834
|
});
|
19754
19835
|
};
|
19755
|
-
prepareCreateIndexesJson = (tableName, schema5, indexes) => {
|
19836
|
+
prepareCreateIndexesJson = (tableName, schema5, indexes, internal) => {
|
19756
19837
|
return Object.values(indexes).map((indexData) => {
|
19757
19838
|
return {
|
19758
19839
|
type: "create_index",
|
19759
19840
|
tableName,
|
19760
19841
|
data: indexData,
|
19761
|
-
schema: schema5
|
19842
|
+
schema: schema5,
|
19843
|
+
internal
|
19762
19844
|
};
|
19763
19845
|
});
|
19764
19846
|
};
|
@@ -20663,7 +20745,12 @@ var init_snapshotsDiffer = __esm({
|
|
20663
20745
|
const typedResult = diffResultSchemeMysql.parse(diffResult);
|
20664
20746
|
const jsonStatements = [];
|
20665
20747
|
const jsonCreateIndexesForCreatedTables = createdTables.map((it) => {
|
20666
|
-
return prepareCreateIndexesJson(
|
20748
|
+
return prepareCreateIndexesJson(
|
20749
|
+
it.name,
|
20750
|
+
it.schema,
|
20751
|
+
it.indexes,
|
20752
|
+
curFull.internal
|
20753
|
+
);
|
20667
20754
|
}).flat();
|
20668
20755
|
const jsonDropTables = deletedTables.map((it) => {
|
20669
20756
|
return prepareDropTableJson(it);
|
@@ -20762,7 +20849,8 @@ var init_snapshotsDiffer = __esm({
|
|
20762
20849
|
return prepareCreateIndexesJson(
|
20763
20850
|
it.name,
|
20764
20851
|
it.schema,
|
20765
|
-
it.addedIndexes || {}
|
20852
|
+
it.addedIndexes || {},
|
20853
|
+
curFull.internal
|
20766
20854
|
);
|
20767
20855
|
}).flat();
|
20768
20856
|
const jsonDropIndexesForAllAlteredTables = alteredTables.map((it) => {
|
@@ -20822,7 +20910,11 @@ var init_snapshotsDiffer = __esm({
|
|
20822
20910
|
(t2) => t2.type === "delete_reference"
|
20823
20911
|
);
|
20824
20912
|
const jsonMySqlCreateTables = createdTables.map((it) => {
|
20825
|
-
return prepareMySqlCreateTableJson(
|
20913
|
+
return prepareMySqlCreateTableJson(
|
20914
|
+
it,
|
20915
|
+
curFull,
|
20916
|
+
curFull.internal
|
20917
|
+
);
|
20826
20918
|
});
|
20827
20919
|
jsonStatements.push(...jsonMySqlCreateTables);
|
20828
20920
|
jsonStatements.push(...jsonDropTables);
|
@@ -20862,7 +20954,7 @@ var init_snapshotsDiffer = __esm({
|
|
20862
20954
|
_meta
|
20863
20955
|
};
|
20864
20956
|
};
|
20865
|
-
applySqliteSnapshotsDiff = async (json1, json2, tablesResolver2, columnsResolver2) => {
|
20957
|
+
applySqliteSnapshotsDiff = async (json1, json2, tablesResolver2, columnsResolver2, prevFull, curFull) => {
|
20866
20958
|
const tablesDiff = diffSchemasOrTables(json1.tables, json2.tables);
|
20867
20959
|
const {
|
20868
20960
|
created: createdTables,
|
@@ -20942,7 +21034,12 @@ var init_snapshotsDiffer = __esm({
|
|
20942
21034
|
return prepareSQLiteCreateTable(it);
|
20943
21035
|
});
|
20944
21036
|
const jsonCreateIndexesForCreatedTables = createdTables.map((it) => {
|
20945
|
-
return prepareCreateIndexesJson(
|
21037
|
+
return prepareCreateIndexesJson(
|
21038
|
+
it.name,
|
21039
|
+
it.schema,
|
21040
|
+
it.indexes,
|
21041
|
+
curFull.internal
|
21042
|
+
);
|
20946
21043
|
}).flat();
|
20947
21044
|
const jsonDropTables = deletedTables.map((it) => {
|
20948
21045
|
return prepareDropTableJson(it);
|
@@ -21044,7 +21141,8 @@ var init_snapshotsDiffer = __esm({
|
|
21044
21141
|
return prepareCreateIndexesJson(
|
21045
21142
|
it.name,
|
21046
21143
|
it.schema,
|
21047
|
-
it.addedIndexes || {}
|
21144
|
+
it.addedIndexes || {},
|
21145
|
+
curFull.internal
|
21048
21146
|
);
|
21049
21147
|
}).flat();
|
21050
21148
|
const jsonDropIndexesForAllAlteredTables = allAltered.map((it) => {
|
@@ -22735,7 +22833,9 @@ var init_migrate = __esm({
|
|
22735
22833
|
squashedPrev,
|
22736
22834
|
squashedCur,
|
22737
22835
|
tablesResolver,
|
22738
|
-
columnsResolver
|
22836
|
+
columnsResolver,
|
22837
|
+
validatedPrev,
|
22838
|
+
validatedCur
|
22739
22839
|
);
|
22740
22840
|
writeResult({
|
22741
22841
|
cur,
|
@@ -22761,7 +22861,9 @@ var init_migrate = __esm({
|
|
22761
22861
|
squashedPrev,
|
22762
22862
|
squashedCur,
|
22763
22863
|
tablesResolver,
|
22764
|
-
columnsResolver
|
22864
|
+
columnsResolver,
|
22865
|
+
validatedPrev,
|
22866
|
+
validatedCur
|
22765
22867
|
);
|
22766
22868
|
return {
|
22767
22869
|
sqlStatements,
|
@@ -112094,7 +112196,7 @@ var init_connections = __esm({
|
|
112094
112196
|
const { migrate } = await import("drizzle-orm/sqlite-proxy/migrator");
|
112095
112197
|
const remoteCallback = async (sql2, params, method) => {
|
112096
112198
|
const res = await fetch2(
|
112097
|
-
`https://api.cloudflare.com/client/v4/accounts/${credentials2.accountId}/d1/database/${credentials2.databaseId}
|
112199
|
+
`https://api.cloudflare.com/client/v4/accounts/${credentials2.accountId}/d1/database/${credentials2.databaseId}/${method === "values" ? "raw" : "query"}`,
|
112098
112200
|
{
|
112099
112201
|
method: "POST",
|
112100
112202
|
body: JSON.stringify({ sql: sql2, params }),
|
@@ -112110,9 +112212,10 @@ var init_connections = __esm({
|
|
112110
112212
|
data.errors.map((it) => `${it.code}: ${it.message}`).join("\n")
|
112111
112213
|
);
|
112112
112214
|
}
|
112113
|
-
const
|
112215
|
+
const result = data.result[0].results;
|
112216
|
+
const rows = Array.isArray(result) ? result : result.rows;
|
112114
112217
|
return {
|
112115
|
-
rows
|
112218
|
+
rows
|
112116
112219
|
};
|
112117
112220
|
};
|
112118
112221
|
const drzl = drizzle(remoteCallback);
|
@@ -116923,7 +117026,9 @@ var init_introspect = __esm({
|
|
116923
117026
|
squashSqliteScheme(drySQLite),
|
116924
117027
|
squashSqliteScheme(schema5),
|
116925
117028
|
tablesResolver,
|
116926
|
-
columnsResolver
|
117029
|
+
columnsResolver,
|
117030
|
+
drySQLite,
|
117031
|
+
schema5
|
116927
117032
|
);
|
116928
117033
|
writeResult({
|
116929
117034
|
cur: schema5,
|
@@ -120465,6 +120570,7 @@ var init_studio2 = __esm({
|
|
120465
120570
|
return {
|
120466
120571
|
dbHash,
|
120467
120572
|
dialect: "sqlite",
|
120573
|
+
driver: "driver" in credentials2 ? credentials2.driver : void 0,
|
120468
120574
|
proxy: sqliteDB.proxy,
|
120469
120575
|
customDefaults,
|
120470
120576
|
schema: sqliteSchema2,
|
package/package.json
CHANGED
package/payload.d.mts
CHANGED
@@ -50,14 +50,14 @@ declare const pgSchema: zod.ZodObject<zod.objectUtil.extendShape<{
|
|
50
50
|
nulls: zod.ZodOptional<zod.ZodString>;
|
51
51
|
opclass: zod.ZodOptional<zod.ZodString>;
|
52
52
|
}, "strip", zod.ZodTypeAny, {
|
53
|
-
expression: string;
|
54
53
|
isExpression: boolean;
|
54
|
+
expression: string;
|
55
55
|
asc: boolean;
|
56
56
|
nulls?: string | undefined;
|
57
57
|
opclass?: string | undefined;
|
58
58
|
}, {
|
59
|
-
expression: string;
|
60
59
|
isExpression: boolean;
|
60
|
+
expression: string;
|
61
61
|
asc: boolean;
|
62
62
|
nulls?: string | undefined;
|
63
63
|
opclass?: string | undefined;
|
@@ -70,8 +70,8 @@ declare const pgSchema: zod.ZodObject<zod.objectUtil.extendShape<{
|
|
70
70
|
}, "strict", zod.ZodTypeAny, {
|
71
71
|
name: string;
|
72
72
|
columns: {
|
73
|
-
expression: string;
|
74
73
|
isExpression: boolean;
|
74
|
+
expression: string;
|
75
75
|
asc: boolean;
|
76
76
|
nulls?: string | undefined;
|
77
77
|
opclass?: string | undefined;
|
@@ -84,8 +84,8 @@ declare const pgSchema: zod.ZodObject<zod.objectUtil.extendShape<{
|
|
84
84
|
}, {
|
85
85
|
name: string;
|
86
86
|
columns: {
|
87
|
-
expression: string;
|
88
87
|
isExpression: boolean;
|
88
|
+
expression: string;
|
89
89
|
asc: boolean;
|
90
90
|
nulls?: string | undefined;
|
91
91
|
opclass?: string | undefined;
|
@@ -163,8 +163,8 @@ declare const pgSchema: zod.ZodObject<zod.objectUtil.extendShape<{
|
|
163
163
|
indexes: Record<string, {
|
164
164
|
name: string;
|
165
165
|
columns: {
|
166
|
-
expression: string;
|
167
166
|
isExpression: boolean;
|
167
|
+
expression: string;
|
168
168
|
asc: boolean;
|
169
169
|
nulls?: string | undefined;
|
170
170
|
opclass?: string | undefined;
|
@@ -211,8 +211,8 @@ declare const pgSchema: zod.ZodObject<zod.objectUtil.extendShape<{
|
|
211
211
|
indexes: Record<string, {
|
212
212
|
name: string;
|
213
213
|
columns: {
|
214
|
-
expression: string;
|
215
214
|
isExpression: boolean;
|
215
|
+
expression: string;
|
216
216
|
asc: boolean;
|
217
217
|
nulls?: string | undefined;
|
218
218
|
opclass?: string | undefined;
|
@@ -336,8 +336,8 @@ declare const pgSchema: zod.ZodObject<zod.objectUtil.extendShape<{
|
|
336
336
|
indexes: Record<string, {
|
337
337
|
name: string;
|
338
338
|
columns: {
|
339
|
-
expression: string;
|
340
339
|
isExpression: boolean;
|
340
|
+
expression: string;
|
341
341
|
asc: boolean;
|
342
342
|
nulls?: string | undefined;
|
343
343
|
opclass?: string | undefined;
|
@@ -410,8 +410,8 @@ declare const pgSchema: zod.ZodObject<zod.objectUtil.extendShape<{
|
|
410
410
|
indexes: Record<string, {
|
411
411
|
name: string;
|
412
412
|
columns: {
|
413
|
-
expression: string;
|
414
413
|
isExpression: boolean;
|
414
|
+
expression: string;
|
415
415
|
asc: boolean;
|
416
416
|
nulls?: string | undefined;
|
417
417
|
opclass?: string | undefined;
|
@@ -636,6 +636,37 @@ declare const schema$1: zod.ZodObject<zod.objectUtil.extendShape<{
|
|
636
636
|
columns: Record<string, string>;
|
637
637
|
tables: Record<string, string>;
|
638
638
|
}>;
|
639
|
+
internal: zod.ZodOptional<zod.ZodObject<{
|
640
|
+
indexes: zod.ZodOptional<zod.ZodRecord<zod.ZodString, zod.ZodOptional<zod.ZodObject<{
|
641
|
+
columns: zod.ZodRecord<zod.ZodString, zod.ZodOptional<zod.ZodObject<{
|
642
|
+
isExpression: zod.ZodOptional<zod.ZodBoolean>;
|
643
|
+
}, "strip", zod.ZodTypeAny, {
|
644
|
+
isExpression?: boolean | undefined;
|
645
|
+
}, {
|
646
|
+
isExpression?: boolean | undefined;
|
647
|
+
}>>>;
|
648
|
+
}, "strip", zod.ZodTypeAny, {
|
649
|
+
columns: Record<string, {
|
650
|
+
isExpression?: boolean | undefined;
|
651
|
+
} | undefined>;
|
652
|
+
}, {
|
653
|
+
columns: Record<string, {
|
654
|
+
isExpression?: boolean | undefined;
|
655
|
+
} | undefined>;
|
656
|
+
}>>>>;
|
657
|
+
}, "strip", zod.ZodTypeAny, {
|
658
|
+
indexes?: Record<string, {
|
659
|
+
columns: Record<string, {
|
660
|
+
isExpression?: boolean | undefined;
|
661
|
+
} | undefined>;
|
662
|
+
} | undefined> | undefined;
|
663
|
+
}, {
|
664
|
+
indexes?: Record<string, {
|
665
|
+
columns: Record<string, {
|
666
|
+
isExpression?: boolean | undefined;
|
667
|
+
} | undefined>;
|
668
|
+
} | undefined> | undefined;
|
669
|
+
}>>;
|
639
670
|
}, {
|
640
671
|
id: zod.ZodString;
|
641
672
|
prevId: zod.ZodString;
|
@@ -683,6 +714,13 @@ declare const schema$1: zod.ZodObject<zod.objectUtil.extendShape<{
|
|
683
714
|
tables: Record<string, string>;
|
684
715
|
};
|
685
716
|
enums: {};
|
717
|
+
internal?: {
|
718
|
+
indexes?: Record<string, {
|
719
|
+
columns: Record<string, {
|
720
|
+
isExpression?: boolean | undefined;
|
721
|
+
} | undefined>;
|
722
|
+
} | undefined> | undefined;
|
723
|
+
} | undefined;
|
686
724
|
}, {
|
687
725
|
tables: Record<string, {
|
688
726
|
name: string;
|
@@ -727,6 +765,13 @@ declare const schema$1: zod.ZodObject<zod.objectUtil.extendShape<{
|
|
727
765
|
tables: Record<string, string>;
|
728
766
|
};
|
729
767
|
enums: {};
|
768
|
+
internal?: {
|
769
|
+
indexes?: Record<string, {
|
770
|
+
columns: Record<string, {
|
771
|
+
isExpression?: boolean | undefined;
|
772
|
+
} | undefined>;
|
773
|
+
} | undefined> | undefined;
|
774
|
+
} | undefined;
|
730
775
|
}>;
|
731
776
|
type SQLiteSchema = TypeOf<typeof schema$1>;
|
732
777
|
|
@@ -911,7 +956,7 @@ declare const schema: zod.ZodObject<zod.objectUtil.extendShape<{
|
|
911
956
|
tables: Record<string, string>;
|
912
957
|
}>;
|
913
958
|
internal: zod.ZodOptional<zod.ZodObject<{
|
914
|
-
tables: zod.ZodRecord<zod.ZodString, zod.ZodOptional<zod.ZodObject<{
|
959
|
+
tables: zod.ZodOptional<zod.ZodRecord<zod.ZodString, zod.ZodOptional<zod.ZodObject<{
|
915
960
|
columns: zod.ZodRecord<zod.ZodString, zod.ZodOptional<zod.ZodObject<{
|
916
961
|
isDefaultAnExpression: zod.ZodOptional<zod.ZodBoolean>;
|
917
962
|
}, "strip", zod.ZodTypeAny, {
|
@@ -927,19 +972,46 @@ declare const schema: zod.ZodObject<zod.objectUtil.extendShape<{
|
|
927
972
|
columns: Record<string, {
|
928
973
|
isDefaultAnExpression?: boolean | undefined;
|
929
974
|
} | undefined>;
|
930
|
-
}
|
975
|
+
}>>>>;
|
976
|
+
indexes: zod.ZodOptional<zod.ZodRecord<zod.ZodString, zod.ZodOptional<zod.ZodObject<{
|
977
|
+
columns: zod.ZodRecord<zod.ZodString, zod.ZodOptional<zod.ZodObject<{
|
978
|
+
isExpression: zod.ZodOptional<zod.ZodBoolean>;
|
979
|
+
}, "strip", zod.ZodTypeAny, {
|
980
|
+
isExpression?: boolean | undefined;
|
981
|
+
}, {
|
982
|
+
isExpression?: boolean | undefined;
|
983
|
+
}>>>;
|
984
|
+
}, "strip", zod.ZodTypeAny, {
|
985
|
+
columns: Record<string, {
|
986
|
+
isExpression?: boolean | undefined;
|
987
|
+
} | undefined>;
|
988
|
+
}, {
|
989
|
+
columns: Record<string, {
|
990
|
+
isExpression?: boolean | undefined;
|
991
|
+
} | undefined>;
|
992
|
+
}>>>>;
|
931
993
|
}, "strip", zod.ZodTypeAny, {
|
932
|
-
|
994
|
+
indexes?: Record<string, {
|
995
|
+
columns: Record<string, {
|
996
|
+
isExpression?: boolean | undefined;
|
997
|
+
} | undefined>;
|
998
|
+
} | undefined> | undefined;
|
999
|
+
tables?: Record<string, {
|
933
1000
|
columns: Record<string, {
|
934
1001
|
isDefaultAnExpression?: boolean | undefined;
|
935
1002
|
} | undefined>;
|
936
|
-
} | undefined
|
1003
|
+
} | undefined> | undefined;
|
937
1004
|
}, {
|
938
|
-
|
1005
|
+
indexes?: Record<string, {
|
1006
|
+
columns: Record<string, {
|
1007
|
+
isExpression?: boolean | undefined;
|
1008
|
+
} | undefined>;
|
1009
|
+
} | undefined> | undefined;
|
1010
|
+
tables?: Record<string, {
|
939
1011
|
columns: Record<string, {
|
940
1012
|
isDefaultAnExpression?: boolean | undefined;
|
941
1013
|
} | undefined>;
|
942
|
-
} | undefined
|
1014
|
+
} | undefined> | undefined;
|
943
1015
|
}>>;
|
944
1016
|
}, {
|
945
1017
|
id: zod.ZodString;
|
@@ -991,11 +1063,16 @@ declare const schema: zod.ZodObject<zod.objectUtil.extendShape<{
|
|
991
1063
|
tables: Record<string, string>;
|
992
1064
|
};
|
993
1065
|
internal?: {
|
994
|
-
|
1066
|
+
indexes?: Record<string, {
|
1067
|
+
columns: Record<string, {
|
1068
|
+
isExpression?: boolean | undefined;
|
1069
|
+
} | undefined>;
|
1070
|
+
} | undefined> | undefined;
|
1071
|
+
tables?: Record<string, {
|
995
1072
|
columns: Record<string, {
|
996
1073
|
isDefaultAnExpression?: boolean | undefined;
|
997
1074
|
} | undefined>;
|
998
|
-
} | undefined
|
1075
|
+
} | undefined> | undefined;
|
999
1076
|
} | undefined;
|
1000
1077
|
}, {
|
1001
1078
|
tables: Record<string, {
|
@@ -1044,11 +1121,16 @@ declare const schema: zod.ZodObject<zod.objectUtil.extendShape<{
|
|
1044
1121
|
tables: Record<string, string>;
|
1045
1122
|
};
|
1046
1123
|
internal?: {
|
1047
|
-
|
1124
|
+
indexes?: Record<string, {
|
1125
|
+
columns: Record<string, {
|
1126
|
+
isExpression?: boolean | undefined;
|
1127
|
+
} | undefined>;
|
1128
|
+
} | undefined> | undefined;
|
1129
|
+
tables?: Record<string, {
|
1048
1130
|
columns: Record<string, {
|
1049
1131
|
isDefaultAnExpression?: boolean | undefined;
|
1050
1132
|
} | undefined>;
|
1051
|
-
} | undefined
|
1133
|
+
} | undefined> | undefined;
|
1052
1134
|
} | undefined;
|
1053
1135
|
}>;
|
1054
1136
|
type MySqlSchema = TypeOf<typeof schema>;
|