Re: [MongoMapper] You got your Sequel in my MongoMapper

23 views
Skip to first unread message

John Nunemaker

unread,
May 3, 2013, 5:15:37 PM5/3/13
to mongo...@googlegroups.com
Interesting. They must hijack symbols in a similar fashion to MM. The :item_created_time.desc is what is tripping it up.

If you do sort("item_created_time desc") it should be ok, but it does stink that they are conflicting.

On May 3, 2013, at 1:23 PM, Steven Crosley <secr...@gmail.com> wrote:

Has anyone ever come across this? I'm using Rails 3.2, with both MongoMapper and Sequel, but I don't have any Sequel models...

I have Sequel gem in my Gemfile for a rake task. Now, I am getting this error in my MongoMapper document:

undefined method `flatten' for #<Sequel::SQL::OrderedExpression:0x007f93a7a5b5f8>

With this query being in my model as a MongoMapper document:

item = self.where(:item_status => 'New' ).sort(:item_created_time.desc).first

When I remove the Sequel gem from my Gemfile, the error goes away. Can the two gems coexist? :)

--
--
You received this message because you are subscribed to the Google
Groups "MongoMapper" group.
For more options, visit this group at
http://groups.google.com/group/mongomapper?hl=en?hl=en
---
You received this message because you are subscribed to the Google Groups "MongoMapper" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mongomapper...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Reply all
Reply to author
Forward
0 new messages