DT
Drizzle Teamβ€’4mo ago
Shayokh

Weird numbers in terminal πŸ’€

After the config and defining schema, I ran
npx drizzle-kit generate
npx drizzle-kit generate
and some weird text with numbers came up. It did create migrations folder with sql though.
PS D:\Typescript\drizzle orm\drizzle_test> npx drizzle-kit generate
No config path provided, using default 'drizzle.config.ts'
Reading config file 'D:\Typescript\drizzle orm\drizzle_test\drizzle.config.ts'
Reading schema files:
D:\Typescript\drizzle orm\drizzle_test\drizzle\schema.ts

←[1m1 tables←[22m
←[1m←[22m←[1m←[34musers ←[39m←[22m ←[90m2 columns 0 indexes 0 fks←[39m

[←[32mβœ“β†[39m] Your SQL migration file ➜ ←[1m←[4m←[34mdrizzle\migrations\0000_worried_crusher_hogan.sql←[39m←[24m←[22m πŸš€
PS D:\Typescript\drizzle orm\drizzle_test> npx drizzle-kit generate
No config path provided, using default 'drizzle.config.ts'
Reading config file 'D:\Typescript\drizzle orm\drizzle_test\drizzle.config.ts'
Reading schema files:
D:\Typescript\drizzle orm\drizzle_test\drizzle\schema.ts

←[1m1 tables←[22m
←[1m←[22m←[1m←[34musers ←[39m←[22m ←[90m2 columns 0 indexes 0 fks←[39m

[←[32mβœ“β†[39m] Your SQL migration file ➜ ←[1m←[4m←[34mdrizzle\migrations\0000_worried_crusher_hogan.sql←[39m←[24m←[22m πŸš€
5 Replies
Shayokh
ShayokhOPβ€’4mo ago
Schema -
import { mysqlTable, serial, varchar } from "drizzle-orm/mysql-core";
import {} from "drizzle-orm/mysql2";

export const UserTable = mysqlTable("users ", {
id: serial("id").primaryKey(),
name: varchar("name", { length: 255 }).notNull(),
});
import { mysqlTable, serial, varchar } from "drizzle-orm/mysql-core";
import {} from "drizzle-orm/mysql2";

export const UserTable = mysqlTable("users ", {
id: serial("id").primaryKey(),
name: varchar("name", { length: 255 }).notNull(),
});
drizzle config -
import { defineConfig } from "drizzle-kit";

export default defineConfig({
schema: "./drizzle/schema.ts",
out: "./drizzle/migrations",
dialect: "mysql",
verbose: true,
strict: true,

dbCredentials: {
url: process.env.DATABASE_URL as string,
},
});
import { defineConfig } from "drizzle-kit";

export default defineConfig({
schema: "./drizzle/schema.ts",
out: "./drizzle/migrations",
dialect: "mysql",
verbose: true,
strict: true,

dbCredentials: {
url: process.env.DATABASE_URL as string,
},
});
Are these texts normal?
rphlmr ⚑
rphlmr βš‘β€’4mo ago
This looks like some color tags that are not well handled by your terminal 🧐 Maybe powershell terminal doesn’t understand them
Shayokh
ShayokhOPβ€’4mo ago
Maybe Just to be clear, its not a major issue right?
rphlmr ⚑
rphlmr βš‘β€’4mo ago
I don't think
Shayokh
ShayokhOPβ€’4mo ago
Thanks a lot! Coming from Prisma as a refugee, I am loving Drizzle so far. Its my go-to ORM now :]
Want results from more Discord servers?
Add your server