Open qazwsxedckll opened 1 week ago
drizzle-orm
0.36.2
drizzle-kit
0.28.0
No response
Using Mysql 8.0.39
Table DDL
CREATE TABLE `alert_history` ( `id` bigint AUTO_INCREMENT NOT NULL, `name` varchar(255) NOT NULL, `description` varchar(255) NOT NULL DEFAULT '', `message` varchar(255) NOT NULL DEFAULT '', `time` timestamp NOT NULL, `alert_type` varchar(255) NOT NULL, `priority` int NOT NULL, `event_name` varchar(255) NOT NULL, `origin` varchar(255) NOT NULL DEFAULT '', `origin_property` varchar(255) NOT NULL DEFAULT '', `origin_property_basetype` varchar(255) NOT NULL DEFAULT '', CONSTRAINT `alert_history_id` PRIMARY KEY(`id`) );
generated schema.ts
export const alertHistory = mysqlTable("alert_history", { id: bigint({ mode: "number" }).autoincrement().notNull(), name: varchar({ length: 255 }).notNull(), description: varchar({ length: 255 }).default(').notNull(), message: varchar({ length: 255 }).default(').notNull(), time: timestamp({ mode: 'string' }).notNull(), alertType: varchar("alert_type", { length: 255 }).notNull(), priority: int().notNull(), eventName: varchar("event_name", { length: 255 }).notNull(), origin: varchar({ length: 255 }).default(').notNull(), originProperty: varchar("origin_property", { length: 255 }).default(').notNull(), originPropertyBasetype: varchar("origin_property_basetype", { length: 255 }).default(').notNull(), }, (table) => { return { idxEntityIdTime: index("idx_entity_id_time").on(table.time), idxEntityIdName: index("idx_entity_id_name").on(table.name), idxTime: index("idx_time").on(table.time), alertHistoryId: primaryKey({ columns: [table.id], name: "alert_history_id"}), } });
the default empty string is missing one '
'
Report hasn't been filed before.
What version of
drizzle-orm
are you using?0.36.2
What version of
drizzle-kit
are you using?0.28.0
Other packages
No response
Describe the Bug
Using Mysql 8.0.39
Table DDL
generated schema.ts
the default empty string is missing one
'