Created
September 9, 2020 13:36
-
-
Save aniruddha27/f3c13b5173dd82639ae5e81aaa784ce2 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Create Compound index | |
db.restaurants.create_index([('borough',pymongo.ASCENDING), | |
('cuisine',pymongo.ASCENDING)], | |
name='borough_cuisine') | |
# Get indexes | |
pprint(db.restaurants.index_information()) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment