From 18b6091da175aa13b59c58b34cfa03bb06a38955 Mon Sep 17 00:00:00 2001 From: Jeffrey Chu Date: Fri, 22 Mar 2013 13:03:11 -0700 Subject: [PATCH] Add quotes around postgresql database name --- library/postgresql_db | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library/postgresql_db b/library/postgresql_db index 09172beed6..327dd39108 100644 --- a/library/postgresql_db +++ b/library/postgresql_db @@ -124,7 +124,7 @@ def db_create(cursor, db, owner, template, encoding): template = " TEMPLATE \"%s\"" % template if encoding: encoding = " ENCODING '%s'" % encoding - query = "CREATE DATABASE %s%s%s%s" % (db, owner, template, encoding) + query = "CREATE DATABASE \"%s\"%s%s%s" % (db, owner, template, encoding) cursor.execute(query) return True elif owner and not db_owned_by(cursor, db, owner):