Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Properly quote CREATE DATABASE parameters in postgresql [#771 state:r…

…esolved]
  • Loading branch information...
commit a6619865d0191c1001d1f25e8f4d111a0e9f78d2 1 parent 104220e
@tarmo tarmo authored
View
6 activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb
@@ -530,13 +530,13 @@ def create_database(name, options = {})
option_string = options.symbolize_keys.sum do |key, value|
case key
when :owner
- " OWNER = '#{value}'"
+ " OWNER = \"#{value}\""
when :template
- " TEMPLATE = #{value}"
+ " TEMPLATE = \"#{value}\""
when :encoding
" ENCODING = '#{value}'"
when :tablespace
- " TABLESPACE = #{value}"
+ " TABLESPACE = \"#{value}\""
when :connection_limit
" CONNECTION LIMIT = #{value}"
else
Please sign in to comment.
Something went wrong with that request. Please try again.