Skip to content

Instantly share code, notes, and snippets.

@prakashthegyan
Created February 8, 2020 07:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save prakashthegyan/6e5d4125d9479cdd98d5c36a3c6c27ce to your computer and use it in GitHub Desktop.
Save prakashthegyan/6e5d4125d9479cdd98d5c36a3c6c27ce to your computer and use it in GitHub Desktop.
import datetime
new_posts = [{"name": "Mike",
"username": "latestpost!",
"date": datetime.datetime(2009, 11, 12, 11, 14)},
{"name": "Eliot",
"title": "onceAgain",
"text": "and pretty easy too!",
"date": datetime.datetime(2009, 11, 10, 10, 45)}]
final = table.insert_many(new_posts)
final.inserted_ids
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment