No way for TypeScript to infer if a column is unique

Currently, there is no way for TypeScript to know if a column is unique, in the same way it is possible to infer if a column is a primary key, or not null, or has default etc. I am trying to create some Types in my project that will allow me to pass the schema for some tables into a type, and infer the columns that are primary keys or are unique. I have outlined all the relevant details including code snippets In this GitHub Issue: https://github.com/drizzle-team/drizzle-orm/issues/4206
0 Replies
No replies yetBe the first to reply to this messageJoin

Did you find this page helpful?