Django连接MongoDB

myclient = pymongo.MongoClient(host=MONGO_HOST, port=MONGO_PORT)
myclient.库.authenticate(MONGO_USER, MONGO_PWD, mechanism='SCRAM-SHA-1')
db = myclient['库']

  

posted @ 2022-08-30 15:18  WrYcF  阅读(40)  评论(0编辑  收藏  举报
Live2D