You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Note that this should work elegantly with the fact that Postgres considers all NULLs unique in createdAt field, so we might need to use a partial unique index:
You're right - the feature is still not implemented. Your solution is interesting. There is no reason that I couldn't create my own Unique decorator that adds this type of index. I'm going to look into whether TypeORM has come up with an elegant solution for this as it seems like a pretty common problem.
Note that this should work elegantly with the fact that Postgres considers all NULLs unique in
createdAt
field, so we might need to use a partial unique index:The text was updated successfully, but these errors were encountered: