summaryrefslogtreecommitdiffstats
path: root/activerecord-3.0.3-postgres-fix.patch
blob: a911e12e291e52ed28f00d564ad328f807cb637d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
--- lib/active_record/connection_adapters/postgresql_adapter.rb.orig	2011-01-18 00:45:58.997405001 -0500
+++ lib/active_record/connection_adapters/postgresql_adapter.rb	2011-01-18 00:47:17.553405015 -0500
@@ -362,6 +362,9 @@ module ActiveRecord
 
       # Quotes column names for use in SQL queries.
       def quote_column_name(name) #:nodoc:
+        unless PGconn.respond_to?(:quote_ident)
+          raise 'Your PostgreSQL connection does not support quote_ident. Try upgrading pg.'
+        end
         PGconn.quote_ident(name.to_s)
       end