import pymongo
client = pymongo.MongoClient(host='localhost', port=27017)
db = client['test']
collection = db.students
student = {'id': '20120001', 'name': 'Bob', 'age': 20, 'gender': 'male'}
result = collection.insert(student)
print(result)

c533d7abdc57bb82025d6da39e7d87a62f9d154b
<mask token>

<mask token>
print(result)

<mask token>
client = pymongo.MongoClient(host='localhost', port=27017)
db = client['test']
collection = db.students
student = {'id': '20120001', 'name': 'Bob', 'age': 20, 'gender': 'male'}
result = collection.insert(student)
print(result)

import pymongo
client = pymongo.MongoClient(host='localhost', port=27017)
db = client['test']
collection = db.students
student = {'id': '20120001', 'name': 'Bob', 'age': 20, 'gender': 'male'}
result = collection.insert(student)
print(result)
