diff options
Diffstat (limited to 'lib/arel/visitors/postgresql.rb')
-rw-r--r-- | lib/arel/visitors/postgresql.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/arel/visitors/postgresql.rb b/lib/arel/visitors/postgresql.rb index 01fbda75b9..0e82a703ca 100644 --- a/lib/arel/visitors/postgresql.rb +++ b/lib/arel/visitors/postgresql.rb @@ -17,7 +17,7 @@ module Arel [ "SELECT * FROM (#{sql}) AS id_list", "ORDER BY #{aliased_orders(o.orders).join(', ')}", - ("LIMIT #{visit o.limit}" if o.limit), + (visit(o.limit) if o.limit), (visit(o.offset) if o.offset), ].compact.join ' ' else |