drizzle-kit doesn't pull foreign keys from supabase/postgres?

It's hard to really turn this into a proper bug report because, honestly, with Supabase there could be many root causes, but basically, when I use drizzle-kit to introspect my Supabase setup, it works pretty well, except: 1. It doesn't include any foreign keys 2. It doesn't include anything that's in the auth schema I think #2 is a known issue? And something that I'll avoid as soon as we switch off of Supabase. But #1 might be something that's new to the drizzle team, so noting it here!
2 Replies
Peter
Peter2y ago
+1 seeing this as well. I've been searching to see if there are any examples of working supabase x DrizzleORM setups out there, but no luck so far. Seeing these 2 things when running introspect + generate as well^ Is it recommended to use Drizzle w/ Supabase (+auth) at the moment?
raaden
raaden2y ago
Not sure if it is related but I am seeing that Primary Keys are not captured against a standard Pg database (not supabase) as well. So it might not be supabase specific. It captured them as notNull but did not define them as primary keys in either the generated sql or schema file.
Want results from more Discord servers?
Add your server