0

I'm working on an application in Delphi using PostgreSQL as a database. I'm actually getting a problem with the connection in design-time: when I try to run a simple query like :

select * from article;

I get a message which says that the table article does not exist whereas it does exist, besides when I execute the program, the query runs correctly.

I note that the TZConnection connects well to the Postgres database at design time.

Any ideas?

tanina
  • 1
  • 1
  • Check that you are connected to the right database. Make sure your search_path is set to the right schema or otherwise use a fully qualified tablename. – clamp Mar 06 '21 at 21:08
  • I'm really connected to the db, in fact I can run a query to a specific table but not to the others. I also tried with `public.tableName` but no response. – tanina Mar 07 '21 at 16:39
  • What do you see when you connect with psql and execute `\dt`? – clamp Mar 07 '21 at 17:03
  • All tables are shown – tanina Mar 07 '21 at 17:08
  • what does `\dp article` show? – clamp Mar 07 '21 at 17:11
  • compare it with `\dp some_other_table` where your queries are successful. – clamp Mar 07 '21 at 17:14
  • It does show all the data from the `article` table, event with the other tables but when I use the `zeos` to query the database it tells me that this one does not exist with error 104. It's very confusing because I tried with `public` schema even though it does not work. – tanina Mar 07 '21 at 17:20
  • If you see the same permissions for both tables in psql, debug your client side: You can set `log_statement = 'all' ` and `log_min_error_statement = 'ERROR'` in postgresql.conf. So you can see what is actually sent to the database. – clamp Mar 07 '21 at 17:35

0 Answers0