> I have quite the same problem - how to use conditional operators.
> If I've not missed something, this is not possible at the moment - so
I believe gobson is able to represent pretty much anything you can do
with the bson standard, so any query you find floating around you can
execute using gobson.
--
Gustavo Niemeyer
http://niemeyer.net
http://niemeyer.net/plus
http://niemeyer.net/twitter
http://niemeyer.net/blog
-- I never filed a patent.
Hey there,
You have to reproduce the same query you have in JSON. If JSON has a list, you'll need a list in bson as well, which is represented by slices in Go, as usual. If you want a generic list for querying purposes, you can easily define a type like this locally:
type L []interface{}