Psycopg2 doesn't like table names that start with a lower case letter

Posted by Count Boxer on Stack Overflow See other posts from Stack Overflow or by Count Boxer
Published on 2010-05-05T15:06:55Z Indexed on 2010/05/05 19:58 UTC
Read the original article Hit count: 175

Filed under:
|
|

I am running ActiveState's ActivePython 2.6.5.12 and PostgreSQL 9.0 Beta 1 under Windows XP.

If I create a table with an upper case first letter (i.e. Books), psycopg2 returns the "Programming Error: relation "books" does not exist" error message when I run the select statement: execute("SELECT * FROM Books"). The same error is returned if I run: execute("SELECT * FROM books"). However, if I change the table to a lower case first name (i.e. books), then either of the above statements works.

Are tables name supposed to have a lower case first name? Is this a setting or a feature or a bug? Am I missing something obvious?

© Stack Overflow or respective owner

Related posts about python

Related posts about postgresql