Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update README.md guide #118

Merged
merged 2 commits into from Jul 10, 2023
Merged

Update README.md guide #118

merged 2 commits into from Jul 10, 2023

Conversation

aathikahamed
Copy link
Contributor

I was getting this error because of using the settings from the readme file.

PrismaClientKnownRequestError:
Invalid `this.prisma[this.sessionModelName].create()` invocation in
D:\Coding Files\admin-server\node_modules\@quixo3\prisma-session-store\dist\lib\prisma-session-store.js:543:85

  540 case 4:
  541     _a.sent();
  542     return [3 /*break*/, 7];
→ 543 case 5: return [4 /*yield*/, this.prisma[this.sessionModelName].create(
The provided value for the column is too long for the column's type. Column: for
    at Rn.handleRequestError (D:\Coding Files\admin-server\node_modules\@prisma\client\runtime\library.js:174:7325)
    at Rn.handleAndLogRequestError (D:\Coding Files\admin-server\node_modules\@prisma\client\runtime\library.js:174:6754)
    at Rn.request (D:\Coding Files\admin-server\node_modules\@prisma\client\runtime\library.js:174:6344)

After doing some research I had to change update this settings on my prisma schema.

Updating this hoping it would be beneficial for someone.

- data      String
+ data      String   @db.MediumText

@kleydon
Copy link
Owner

kleydon commented Jul 10, 2023

@aathikahamed - Thanks for the contribution!

Any chance you can specify which database you found this fix useful for? (Does it apply to one database in particular, or does it apply across all of the databases that Prisma supports)?

Thanks again,

-K

@aathikahamed
Copy link
Contributor Author

Not sure on whether this applies to all the databases.

In my case I'm using the PlanetScale MySQL database.

Also, this is where I found for the fix.

@kleydon
Copy link
Owner

kleydon commented Jul 10, 2023

Got it - thanks for the context.

@kleydon kleydon merged commit d438ee3 into kleydon:master Jul 10, 2023
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants