Lighthouse has a new layout. Prefer the old one? Return to the old layout, and switch back any time from the link at the top of each page.

This project is archived and is in readonly mode.

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

#5598

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'

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

State: stale
Milestone: none
Assigned to: Aaron Patterson Aaron Patterson
Importance: Low

Activity

  1. Aaron Patterson
    Aaron Patterson
    • State changed from new to needs-more-info
    • Importance changed from to Low

    Hey Ray! I tried reproducing this bug. I guess I need more info. Can you provide anything else like a failing test or something? Thanks.

    September 23rd, 2010 @ 12:27 AM

  2. David Trasbo
    David Trasbo

    I too was unable to reproduce this.

    September 25th, 2010 @ 06:42 PM

  3. Aaron Patterson
    Aaron Patterson
    • State changed from needs-more-info to stale

    Closing as I couldn't reproduce and this ticket is pretty old.

    October 30th, 2010 @ 10:53 PM