louischatriot / nedb

The JavaScript Database, for Node.js, nw.js, electron and the browser
MIT License
13.49k stars 1.03k forks source link

is or will there be support for cursor.forEach like in mongo? #430

Open dotob opened 8 years ago

dotob commented 8 years ago

see https://docs.mongodb.com/manual/reference/method/cursor.forEach/

what would be the next best thing to do in nedb to iterate efficiently over all documents of a large collection?

jampy commented 8 years ago

Since nedb keeps all it's data in memory anyway I guess you can simple use find() and it's still the most efficient method.