For some reason I am facing this issue that in existing database I have a user table, where I have stored data manually, but when I am trying to access it through the query I get this error
ERROR: relation "user" does not exist
Can you kindly let me know, what may be the cause of this error. Just to mention here I am able to access all the other tables present in the database.
2
Answers
It’s reserved word in PostgreSQL, so if you going to use a table named like that you need to wrap that name in double quotes.
Check if you’re using the correct schema. For example, if the
user
table is in thepublic
schema, you should use the query like:It’s possible too that the table was not created or named correctly, or there may be an issue with the schema or permissions.