This project is archived and is in readonly mode.

#5598 ✓stale
Ray

Arel needs to convert symbols passed to .order() into double quoted strings for PostgreSQL

Reported by Ray | September 9th, 2010 @ 10:20 PM

This works:

Business.order('name')

This fails:

Business.order(:name)

The error is:

ActiveRecord::StatementInvalid: PGError: ERROR: non-integer constant in ORDER BY
LINE 1: SELECT "businesses".* FROM "businesses" ORDER BY 'name'

Comments and changes to this ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

<h2 style="font-size: 14px">Tickets have moved to Github</h2>

The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>

Pages