[opencms-dev] Postgres database creation: Database could not be created! (Error executing SQL statement)

Graham Leggett minfrin at sharp.fm
Sun Feb 13 13:17:22 CET 2005


Hi all,

While trying to create a Postgres database on OpenCMS v6 alpha 3, it 
throws the following error:

Database could not be created!
Error executing SQL statement: CREATE DATABASE opencms.www.site.co.za 
WITH ENCODING='UNICODE' OWNER=opencms
-------------------------------------------
java.sql.SQLException: ERROR: parser: parse error at or near "." at 
character 33

Doing some checking on the way that postgres implements it's "createdb" 
command, the query above is missing inverted commas, it should look like 
this:

CREATE DATABASE "opencms.www.site.co.za" WITH ENCODING='UNICODE' 
OWNER="opencms"

Leaving out the inverted commas means that database names containing 
dots and dashes cannot be used. Is it possible that this database 
creation script be changed?

Regards,
Graham
--
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 3220 bytes
Desc: S/MIME Cryptographic Signature
URL: <https://webmail.opencms.org/pipermail/opencms-dev/attachments/20050213/422320f7/attachment.bin>


More information about the opencms-dev mailing list