kiryl_ch
Explore posts from serversDTDrizzle Team
•Created by kiryl_ch on 5/10/2024 in #help
how to query based on relation?
I have many to many relation between Project and User table. How to querry all projects that user is into?
db.query.projects.findMany({
where: ---> users include userId ?
with: {
users: true,
},
});
2 replies
KKinde
•Created by kiryl_ch on 4/30/2024 in #💻┃support
How to setup SSO only for one organization?
i am building multy tenancy app and what to know if it is possible to setup SSO only for one oraganization? I can not find it in my dashboard
2 replies
gen_random_uuid not working
hi. I am trying to use postgress db provisioned on railway with drizzle. my schema look like
id: uuid('id').default(sql'gen_random_uuid()')
but on insert into this db I get error
PostgresError: null value in column "id" of relation "file" violates not-null constraint
is it possible that my db does not have this function? if so what should I do to create column with autogenerated uuid ? thanks!5 replies
how to restore postgres db from dumb?
i was given my db archives because my db was deleted due to migration. I am trying to restore the db data by running this command pg_restore -U <username> -h <host> -p <port> -W -F t -d <db_name> <dump_file_name> but I am getting error pg_restore: error: could not find header for file "toc.dat" in tar archive
33 replies