Order an Active Record Relation with a custom method

后端 未结 0 1034
醉酒成梦
醉酒成梦 2021-02-01 22:52

I have to order an ActiveRecord Relation

Profile.where(id: [1,2,3])

where records with country_code = \'US\' (or a specific string) first. I\'ve created this self.

相关标签:
回答
  • 消灭零回复
提交回复
热议问题