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

Started by Ivan Volfover 19 years ago2 messagesbugs
Jump to latest
#1Ivan Volf
insys@st.t-com.hr

The following bug has been logged online:

Bug reference: 2726
Logged by: Ivan Volf
Email address: insys@st.t-com.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;

#2Tom Lane
tgl@sss.pgh.pa.us
In reply to: Ivan Volf (#1)
Re: BUG #2726: reindex database failed if number is in database name

"Ivan Volf" <insys@st.t-com.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