Skip to content

Commit

Permalink
Merge pull request jruby#92 from jdmorani/master
Browse files Browse the repository at this point in the history
Rails 3.1 support for postgresql
  • Loading branch information
nicksieger committed Aug 24, 2011
2 parents 5e4ea72 + fcb01c1 commit 84bee95
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions lib/arjdbc/postgresql/adapter.rb
Expand Up @@ -101,8 +101,9 @@ def adapter_name #:nodoc:
'PostgreSQL'
end

def arel2_visitors
{'jdbcpostgresql' => ::Arel::Visitors::PostgreSQL}

def visitor_for(pool) # :nodoc:
::Arel::Visitors::PostgreSQL.new(pool)
end

def postgresql_version
Expand Down Expand Up @@ -246,6 +247,8 @@ def pk_and_sequence_for(table) #:nodoc:
end

def pg_insert(sql, name = nil, pk = nil, id_value = nil, sequence_name = nil, binds = [])
sql = substitute_binds(sql, binds)

# Extract the table from the insert sql. Yuck.
table = sql.split(" ", 4)[2].gsub('"', '')

Expand Down

0 comments on commit 84bee95

Please sign in to comment.