mardi 3 mars 2015

mongoid, query with element in array

I have structure class like this:



#<Transaction _id: 54d46d6a6e6f626fbcc70000, _keywords: ["1", "test1", "test2", "abc1", "projectmongo", "last2", "taka"]>


array keyword map with: [field1, field2,...] So I want to query to get all transaction have field1 == "1" Is this possible?


Aucun commentaire:

Enregistrer un commentaire