I’m just starting out with mongo and python and am stuck on getting this query to run properly:
#get a database
db = connection.test
#get a colleciton
family = db.family
#get all names that begin with E
namesWithE = family.find({'name' : 'E/^'})
print nameWithE.count()
I know there are two records that will match this query but I keep getting a count of 0
–> this works for me