Recommended Docker Compose Workflow
docker-compose.yaml
...$count with relation api returning wrong values ( 2 instead of 0)
Is it possible to have conditional foreign key relation?
Missing schema from generated SQL when using `.toSQL()` on a query style SQL query.
.toSQL()
on a query (db.query.someTable) but it doesn't include the schema for the target tables.
I want to use the .toSQL()
to then pass the SQL and params to electric-sql to sync things I'm running drizzle on the browser.
I didn't find the PGLite driver tag to use....insert from select
Drizzle zod infer wrong type

How to handle multiple unique constraints with onConflictDoUpdate?
unique("unique_game").on(table.idTeamHome, table.idTeamAway, table.time),
unique("unique_id").on(table.idEvent),
unique("unique_game").on(table.idTeamHome, table.idTeamAway, table.time),
unique("unique_id").on(table.idEvent),
Best practices for inferring types in queries?
Already exits error
npx drizzle-kit migrate
without an error, but when my application's build process on the vercel, I am getting that error
TypeScript Error
Is it possible to run migrations on a local dev D1 db?
Cant figure out how to converting a sql query to drizzle syntax
PostgresError: type "vector" does not exist
Unable to update because it is saying field does not exist in schema
keyword
field in stores
however I am getting the following error:
Object literal may only specify known properties, and 'keyword' does not exist in type '{ name?: string | SQL<unknown> | PgColumn<ColumnBaseConfig<ColumnDataType, string>, {}, {}>; }'.ts(2353)
Object literal may only specify known properties, and 'keyword' does not exist in type '{ name?: string | SQL<unknown> | PgColumn<ColumnBaseConfig<ColumnDataType, string>, {}, {}>; }'.ts(2353)

Primary and Replica Query Load Balancing
Is there a valid use case for being able to specify a relation name that points to a "wrong" table?
client does not exist in type "NeonClient"

composite primary key migration fail
drizzle-kit --custom --name=recipient-primary-key
to generate a custom migration file. In that file i have the following sql
```sql
-- Step 1: Rename the old recipients table
ALTER TABLE recipients RENAME TO recipients_old;...Dynamic select() query builder
.$dynamic()
operator, we're able to double up on .where()
and .limit()
additions without erroring. However, we can't add on to the original select()
query. Is there a way to do this to add new fields to an existing query being built?Updating a date with the node-postgres adapter
``ts
await db
.update(schema.order)
.set({ completedDate: new Date() }) // same error with sql
now()`...