Insert the $currentDate on mongodb with pymongo
问题 I need test the accuracy of a server mongodb. I am trying to insert a sequence of data, take the moment and it was sent to the database to know when it was inserted. I'm trying this: #!/usr/bin/python from pymongo import Connection from datetime import date, timedelta, datetime class FilterData: @classmethod def setData(self, serialData): try: con = Connection('IP_REMOTE', 27017, safe=True) db = con['resposta'] inoshare = db.resposta inoshare.insert(serialData) con.close() except Exception as