I have interesting situation with Postgres (similar to PostgreSQL "Column does not exist" but it actually does). I.e. column or table name contains capital letters. In given link above it is about table name.
In my case, in database i have a column "projectId" defined in camelCase (SQL in DB looks like '.. "projectId" integer NOT NULL,..'). In Backend I use Java with Hibernate. When i try to get all entries of the table with named query e.g. "SELECT e FROM ProjectTa e" i get the error:
org.hibernate.exception.SQLGrammarException: could not extract ResultSet
Caused by: org.postgresql.util.PSQLException: ERROR: column projectta0_.projectid does not exist
Hinweis: Perhaps you meant to reference the column "projectta0_.projectId".
Position: 138
SQL log:
select projectta0_.id as id1_1_, projectta0_.budget as budget2_1_, projectta0_.completion as completi3_1_, projectta0_.name as name4_1_, projectta0_.projectId as projectI5_1_, p
rojectta0_.status as status6_1_, projectta0_.users as users7_1_ from project_ta projectta0_
'FROM "Tablename" ' will solve the problem for table name. How must i adjust my named query if I want just all entries of table. (i do not want to change column name or use name for @Column in my entity)