You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Mongoid
Hi,
I am wondering why Integer strings store strings when the string that
you assign is non numeric.
ActiveRecord assigns at that point 0, but in Mongoid when you do
integer_field = "asd" it would actually
save "asd" which is pretty strange behaviour. What is the reasoning
behind that? Shouldn't it
default to 0 if the string is non numeric?
Cheers!
Nick Hoffman
unread,
Feb 11, 2012, 1:32:05 PM2/11/12
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to mon...@googlegroups.com
Hey Piotr. Mongoid should try to cast the string to an integer (Eg: "4asdf" becomes 4), or just store 0. Could you open an issue in GitHub for this, please?