Re: Case sensitivity in psql/pg_dump

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: Michal Schwarz <misch(at)czechin(dot)cz>
Cc: "'pgsql-bugs(at)postgresql(dot)org'" <pgsql-bugs(at)postgresql(dot)org>
Subject: Re: Case sensitivity in psql/pg_dump
Date: 2002-04-16 19:27:08
Message-ID: 200204161927.g3GJR8R28419@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs


Sorry to sound like a broken record, but this is also fixed in 7.2.1.

---------------------------------------------------------------------------

Michal Schwarz wrote:
> Problem:
> --------
> pg_dump does not honour case-sensitivity in user names, which results to
> failures when restoring database.
>
> Environment:
> ------------
> Version: PostgreSQL 7.2 on i686-pc-linux-gnu, compiled by GCC 2.95.2
> System: Linux jtam.brno.czechin.cz 2.2.17-RAID #8 SMP Mon Oct 16 10:48:13
> CEST 2000 i686 unknown
>
> Exact steps to reproduce this bug:
> ----------------------------------
> Run "psql template1"
>
> template1=> CREATE USER "BLBEC" WITH CREATEDB;
> CREATE USER
> template1=> \c - "BLBEC"
> You are now connected as new user BLBEC.
> template1=> CREATE DATABASE blbectest;
> CREATE DATABASE
> template1=> \c blbectest "BLBEC"
> You are now connected to database blbectest as user BLBEC.
> template1=> CREATE TABLE test (a INT);
> CREATE
> template1=> \q
>
> Then run "pg_dump blbectest". Result will contain command '\connect -
> BLBEC', which is incorrect, because user name 'BLBEC' should be enclosed by
> quotes. Psql 7.1 worked even withoud quotes and connected as user 'BLBEC',
> while psql 7.2 fails with error:
>
> FATAL 1: user "blbec" does not exist
> Previous connection kept
>
> Ie. psql 7.2 obviously EXPECTS quotes, while pg_dump and pg_dumpall DO NOT
> GENERATE them.
>
> bye,
> --
> Michal Schwarz
>
> ---------------------------(end of broadcast)---------------------------
> TIP 1: subscribe and unsubscribe commands go to majordomo(at)postgresql(dot)org
>

--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 853-3000
+ If your life is a hard drive, | 830 Blythe Avenue
+ Christ can be your backup. | Drexel Hill, Pennsylvania 19026

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Geoffrey Ritchey 2002-04-16 22:47:37 Unknown Response Type [some random character]
Previous Message Bruce Momjian 2002-04-16 19:26:10 Re: replace_vars_with_subplan_refs