Thread: BUG #2742: psql -c is not case sensitive

BUG #2742: psql -c is not case sensitive

From
""
Date:
The following bug has been logged online:

Bug reference:      2742
Logged by:
Email address:      chad.wilson@ngc.com
PostgreSQL version: 8.0rc5
Operating system:   Linux Red Hat 8
Description:        psql -c is not case sensitive
Details:

psql -c is not case sensitive...

If a schema is created with the command
    psql -d dbname -c "CREATE SCHEMA "SCHEMA_name"
and is executed at the command line, then a schema is created for dbname
with the name schema_name.

If a schema is created with the commands
    psql dbname
    CREATE SCHEMA "SCHEMA_name";
and is executed from the psql command, then a schema is created for dbname
with the name SCHEMA_name.

Does this appear to be a bug?

Re: BUG #2742: psql -c is not case sensitive

From
Tom Lane
Date:
"" <chad.wilson@ngc.com> writes:
> If a schema is created with the command
>     psql -d dbname -c "CREATE SCHEMA "SCHEMA_name"
> and is executed at the command line, then a schema is created for dbname
> with the name schema_name.

I think you need to reflect on the properties of the shell's quoting
conventions --- that will come through to psql and hence the backend
with no quotes.

            regards, tom lane