Repository navigation
Replies: 4 comments 1 reply
|
getting errors when i open the User entity on prisma studio too. Here's the "error details" it shows. this led me to delete all db and migration and "start over"... and now both the seed script and studio fails on any empty table. seed.ts: studio with the error above. |
0 replies
|
can't explain what is going on... (note, seed.ts only adds missing entries, doesn't delete anything, there's only calls to |
0 replies
|
with an empty seed.ts file: |
0 replies
|
apparently the but worked around this mess with:
|
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Question
db pushcreates the slqite DB just fine. Butmigrate resetwipes it and only creates an empty migrations table before trying to run the seed, which fails as there's no table anywhere.original:
Why I'm now (might be 6.6.0 regression... still working on validating older versions) getting this error when using
.findUnique()or.findFirst()?When the referenced 1:0-1 relation is missing, I get a new error, which seems to imply i'm using executeRaw()...
this error goes away if i either: remove the
include:{ profile: true}or create an entry on the profile to match the 1:0-1 relation.How to reproduce (optional)
my schema have an optional 1:1 (1:0-1?)
User { id @id ... profile Profile? ... } Profile { id @id user User @relation(fields: [userId], references: [id]) userId Int @unique dateOfBirth DateTime? ... }Expected behavior (optional)
query succeeds with
user.profilebeingnull?Information about Prisma Schema, Client Queries and Environment (optional)
All reactions