On Thu, 08 Feb 2001 19:23:47 Ben Leslie wrote:
>Just running into a few problems involving the case of table names.
>
>I am writing a program that dynamically maps python objects into
>postgres tables. These classes have mixed case names such as "BaseObject",
>"AbcXyzObject" etc.
>
>I call CREATE TABLE using the mixed case table name I want eg:
>
>CREATE TABLE BaseObject (trivial int4);
If you need to preserve the case, you will have to use double quotes when
creating and querying:
CREATE TABLE "BaseObject" (trivial int4);
SELECT * from "BaseObject";
This also applies to attributes (column names).
Tony
--
Anthony E. Greene <agreene@pobox.com> <http://www.pobox.com/~agreene/>
PGP Key: 0x6C94239D/7B3D BD7D 7D91 1B44 BA26 C484 A42A 60DD 6C94 239D
Chat: AOL/Yahoo: TonyG05 ICQ: 91183266
Linux. The choice of a GNU Generation. <http://www.linux.org/>