BUG #2726: reindex database failed if number is in database name

Lists: pgsql-bugs
From: "Ivan Volf" <insys(at)st(dot)t-com(dot)hr>
To: pgsql-bugs(at)postgresql(dot)org
Subject: BUG #2726: reindex database failed if number is in database name
Date: 2006-10-31 17:49:49
Message-ID: 200610311749.k9VHnnBQ026601@wwwmaster.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-bugs


The following bug has been logged online:

Bug reference: 2726
Logged by: Ivan Volf
Email address: insys(at)st(dot)t-com(dot)hr
PostgreSQL version: 8.1
Operating system: linux
Description: reindex database failed if number is in database name
Details:

drin=# reindex database test;
NOTICE: table "pg_class" was reindexed
NOTICE: table "sql_features" was reindexed
NOTICE: table "sql_implementation_info" was reindexed
NOTICE: table "sql_languages" was reindexed

drin=# reindex database 06test;
ERROR: syntax error kod ili u blizini "06" at character 18
LINE 1: reindex database 06test;


From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Ivan Volf" <insys(at)st(dot)t-com(dot)hr>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #2726: reindex database failed if number is in database name
Date: 2006-10-31 21:53:17
Message-ID: 9216.1162331597@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-bugs

"Ivan Volf" <insys(at)st(dot)t-com(dot)hr> writes:
> drin=# reindex database 06test;
> ERROR: syntax error kod ili u blizini "06" at character 18

This isn't a bug. If you want to use names that aren't ordinary
identifiers, you need to double-quote them.

regards, tom lane