How can get all Document in a Database in CouchBase Lite (Android)?


#1

Hello everyone,
I have a question , I have a Database and in this, i have many documents. So, How I can get all documents ?
Thank you before.


#2

You can use the all docs query to get all the documents stored in cb lite.

For custom queries, check out the Query guide which explains how to create map/reduce queries and the different options you can use with them: http://developer.couchbase.com/mobile/develop/guides/couchbase-lite/native-api/query/index.html

I also recommend you to watch the presentation Jens gave at Couchbase Connect last year: https://www.youtube.com/watch?v=mFQTGiCEHrE

James


#3

Thank you very much :slight_smile: