Skip to content

Instantly share code, notes, and snippets.

@trishagee
Created May 6, 2014 17:57
Show Gist options
  • Save trishagee/7ced271e6ee5d0bdc0c3 to your computer and use it in GitHub Desktop.
Save trishagee/7ced271e6ee5d0bdc0c3 to your computer and use it in GitHub Desktop.
List<Integer> books = Arrays.asList(27464, 747854);
DBObject person = new BasicDBObject("_id", "jo")
.append("name", "Jo Bloggs")
.append("address", new BasicDBObject("street", "123 Fake St")
.append("city", "Faketon")
.append("state", "MA")
.append("zip", 12345))
.append("books", books);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment