Forum: Ruby on Rails Gem Mongoid: multiples order_by in embbeds_many not work?

4995e71aff71f480d4f19c65c083a307?d=identicon&s=25 Rodrigo Mendonça (Guest)
on 2014-08-26 17:16
(Received via mailing list)
Example:
School embeds_many :students

In rails console:
School.first.students.order_by(:name.asc, :email.desc)

Works with name. but why ordering from second field (email) not work??
It's
a bug?

I opened an issue in mongoid gem, but maybe it's a mongodb problem
insted
https://github.com/mongoid/mongoid/issues/3782


--
Please log in before posting. Registration is free and takes only a minute.
Existing account

NEW: Do you have a Google/GoogleMail, Yahoo or Facebook account? No registration required!
Log in with Google account | Log in with Yahoo account | Log in with Facebook account
No account? Register here.