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
I face a issue with Providers and my database model. Indeed i have a database legacy with user id as number not string or uuid :
In type "DefaultPostgresUsersTable" for exemple :
the column definition for id is : "PgVarchar" | "PgText" | "PgUUID" not working in getUser(userId: string) querie in adapter... no user found.
If it's possible, i wouldn't create my own adapter just to override the queries and types ...
it's possible to add this ? and make it work ?
i think i'm not the only one.
Or any ideas to achieve that ?
Thanks
Background
I think, i'm not the only one in this case
Proposal
use a custom schema.usersTable and
Refactor to accept PgInteger in types and refactor these methods :
getUser(userId: string | number),
createSession(data: {
sessionToken: string
userId: string | number
expires: Date
})
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Goals
I face a issue with Providers and my database model. Indeed i have a database legacy with user id as number not string or uuid :
In type "DefaultPostgresUsersTable" for exemple :
the column definition for id is : "PgVarchar" | "PgText" | "PgUUID" not working in getUser(userId: string) querie in adapter... no user found.
If it's possible, i wouldn't create my own adapter just to override the queries and types ...
it's possible to add this ? and make it work ?
i think i'm not the only one.
Or any ideas to achieve that ?
Thanks
Background
I think, i'm not the only one in this case
Proposal
use a custom schema.usersTable and
Refactor to accept PgInteger in types and refactor these methods :
sessionToken: string
userId: string | number
expires: Date
})
Beta Was this translation helpful? Give feedback.
All reactions