Updates
This commit is contained in:
@@ -27,14 +27,14 @@ function generateTypeDefinition({ paradigm, table, query, typeDefName, allValues
|
||||
})
|
||||
.join(" | ");
|
||||
}
|
||||
if ((_a = schemaType.dataType) === null || _a === void 0 ? void 0 : _a.match(/int/i)) {
|
||||
if ((_a = schemaType.dataType) === null || _a === void 0 ? void 0 : _a.match(/int|double|decimal/i)) {
|
||||
return "number";
|
||||
}
|
||||
if ((_b = schemaType.dataType) === null || _b === void 0 ? void 0 : _b.match(/text|varchar|timestamp/i)) {
|
||||
return "string";
|
||||
}
|
||||
if ((_c = schemaType.dataType) === null || _c === void 0 ? void 0 : _c.match(/boolean/i)) {
|
||||
return "boolean";
|
||||
return "0 | 1";
|
||||
}
|
||||
return "string";
|
||||
}
|
||||
|
||||
@@ -89,8 +89,12 @@ function default_1(_a) {
|
||||
tableId = newTableEntryRes.postInsertReturn.insertId;
|
||||
}
|
||||
}
|
||||
if (newTableSchema.tableNameOld) {
|
||||
}
|
||||
// if (newTableSchema.tableNameOld) {
|
||||
// const renameTable = await dbHandler({
|
||||
// query: `RENAME TABLE \`${targetDatabase}\`.\`${newTableSchema.tableNameOld}\` TO \`${targetDatabase}\`.\`${newTableSchema.tableName}\``,
|
||||
// noErrorLogs: true,
|
||||
// });
|
||||
// }
|
||||
return tableId;
|
||||
}
|
||||
catch (error) {
|
||||
|
||||
Reference in New Issue
Block a user