The following bug has been logged on the website: Bug reference: 7587 Logged by: John Bradshaw Email address: f...@johnbradshaw.org PostgreSQL version: 9.1.6 Operating system: Ubuntu 12.04 LTS Description:
createdb allows illegal period/dot (".") in DB names. Can't ALTER DATABASE name in psql as it doesn't allow periods/dots in database names. Had to dropdb (which also allows dot in names) and recreate from dump. Would be nice if createdb checked for illegal characters in DB names. postgres@dev2:~$ psql -V psql (PostgreSQL) 9.1.6 contains support for command-line editing postgres@dev2:~$ sudo dpkg -l postgresql-9.1 Desired=Unknown/Install/Remove/Purge/Hold | Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend |/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad) ||/ Name Version Description +++-===============================================-===============================================-============================================================================================================== ii postgresql-9.1 9.1.6-0ubuntu12.04 object-relational SQL database, version 9.1 server postgres@dev2:~$ createdb badname.sql postgres@dev2:~$ psql badname.sql psql (9.1.6) Type "help" for help. badname.sql=# alter DATABASE badname.sql RENAME TO to goodname; ERROR: syntax error at or near "." LINE 1: alter DATABASE badname.sql RENAME TO to goodname; ^ badname.sql=# \q postgres@dev2:~$ dropdb badname.sql -- Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-bugs