Database Viewer Crashes Entire Site if Table doesn't have Primary Key
ae-hopscotch
HOBBYOP
2 years ago
Steps to reproduce:
- Create a new project
- Provision a PostgreSQL Database with default settings
- Add a table to the database with no primary key. (I did this through my project's
npx knex-migrate up, and I'm not sure whether the UI allows you to do this. If the UI doesn't allow, you can also connect to the database externally to create a new table without a pkey) - Click on the table in the Railway Database Data Viewer
- Click on a row.
Expected: I can see the data (or at least a popup error).
Actual: The entire site crashes and says "Application Error: a client-side exception has occurred..."
The console error indicates that this is the case.
Error: No PRIMARY KEY. Please set one in order to be able to edit/delete.
NextJS 11
4 Replies
2 years ago
Thank you for the report, I have ticketed this and will let you know when fixed!
2 years ago
Hello!
This has been fixed, can you let me know if you can reproduce it or reproduce a similar issue?
ae-hopscotch
HOBBYOP
2 years ago
This appears to be fixed, thank you! 🚂
Status changed to Solved brody • over 1 year ago
