I just tested modifying a table in my PostgreSQL db through DBeaver and it seems to have broken the db when looking at the data from the Hasura (Graphql) console. I simply added a column from Dbeaver. In Hasura I get an error "no such column exists". Anyone have any idea why or how I can fix this?
no such column exists for PostgreSQL db in Hasura (Graphql) console when adding column via DBeaver
Asked Answered
Could you show us your SQL statements that altered that table? And why do you think you broke the database? Are there any error messages in your PostgreSQL server log? And Yes, it looks like Hasura is looking for a column that doesn't exist (anymore). You could create that column, if you know what column it is. –
Firry
Thanks @FrankHeikens. It was a conflict in the meta data in the console. –
Misrule
Hasura support helped me pinpoint it to the metadata stored in the Graphql console. Hope this helps someone else save a little time.
"If you make DDL changes to your database from outside Hasura, you must manually reload the Hasura metadata so that Hasura knows that something has changed and it adapts to those changes accordingly.You can reload the metadata by clicking on the settings icon on the top right in console."
And don't forget to add permission for new colunns for roles other than "admin" –
Cumquat
I had to check "Reload all databases" as well –
Backhouse
you have to update the metadata, from the console it would be:
hasura metadata reload
You need to reload the metadata so Hasura knows that new data has been added. Click the gear icon > Reload metadata > Reload
© 2022 - 2024 — McMap. All rights reserved.