Created
December 18, 2013 23:19
-
-
Save tleyden/8031592 to your computer and use it in GitHub Desktop.
Query for Person objects
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Query query = view.createQuery(); | |
QueryEnumerator queryEnumerator = query.run(); | |
while (queryEnumerator.hasNext()) { | |
QueryRow row = queryEnumerator.next(); | |
Document document = database.getDocument(row.getDocumentId()); | |
Person person = new Person(document); | |
person.setName(person.getName() + "."); | |
person.save(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment