Reputation: 185
I'm getting this weird error. I am following the documentation closely and don't understand what I am doing wrong. I pasted an minimal example to replicate the error. Any tip to this fix?
Error message:
TypeError: 'Collection' object is not callable. If you meant to call the 'dictinct' method on a 'Collection' object it is failing because no such method exists.
Code:
import pymongo
client = pymongo.MongoClient('mongodb://localhost:27017')
detached = client['realestate'].detached
print(detached.dictinct('key_facts-build_year'))
Upvotes: 0
Views: 173