My fault! I deprecated it before actually refactoring it, then I decided not to refacotry and I forgot the warning. Bottom line order_by is not the same as order.
Please, ignore the deprecation warning. (I will remove that). ciao dd On Thu, May 19, 2011 at 11:40 AM, Donald R. Ziesig <[email protected]>wrote: > While reviewing my logs for deprecations, I found: > > Automatic scope* :order_b*y has been deprecated: use *:order *instead. > > so, being a.conscientious developer ;-) , I changed all occurrences > of*:order_by > * associated with apply_scopes to* :order*. > > The beta testers immediately raised a hue and cry about many things being > broken! Tried it myself and sure enough, I got the following error > everywhere the modified apply_scopes invocation occurred: > > ActiveRecord::StatementInvalid (PGError: ERROR: syntax error at or near > "asc" > LINE 1: ..._types".* FROM "transaction_types" ORDER BY name, asc LIMIT ... > ^ > : SELECT "transaction_types".* FROM "transaction_types" ORDER BY name, asc > LIMIT 30 OFFSET 0): > app/controllers/transaction_types_controller.rb:12:in `index' > > (note the caret is pointing to asc). > > changed the code associated with "transaction_types" from *:order* to * > :order_by* and the error went away but the deprecation warning returned. > > I am using pre31. Has this been fixed in a later release? > > Don Z. > > -- > You received this message because you are subscribed to the Google Groups > "Hobo Users" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]. > For more options, visit this group at > http://groups.google.com/group/hobousers?hl=en. > -- You received this message because you are subscribed to the Google Groups "Hobo Users" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/hobousers?hl=en.
