final documents = await databases.listDocuments(
databaseId: AppwriteClientHelper.databaseId,
collectionId: AppwriteClientHelper.vocabularyCollectionId,
queries: [
Query.select([]),
Query.equal("language", languageSelected.languageId),
// Query.limit(10),
Query.orderDesc("\$updatedAt")
]);
I have a 39 total documents in my collection. Now, when I fetch all the documents why only it gives me 25 documents? as you can see in my code I already commented out the Query.limit,
The default limit is 25
Then how can I fetch all the list of my documents? without limiting?
is it okay to set the limit to 1000 Query.limit(1000)
because I am going to create a script to export all documetns
Max limit is 100
I really recommend cursor-based pagination with a limit of 100 or so...but, technically, we have removed the max limit, so you can pass a really big number for limit if you really wanted to
Appwrite now allows a larger limit in the query? I've been doing while loop with a flag called "isMore" and check the return docs (if it reaches 100) and then querying again with offset going up
How much can you query now?
as high as you want...but i recommend sticking with your previous implementation
Ok
Just to complement your answer take a look this article about pagination, the benchmarks are really interesting
https://itnext.io/the-best-database-pagination-technique-is-530abf2aab51
Recommended threads
- Introducing new string column types made...
Adding new string types is hugely bennificial! Unfortunately it made the current column types not editable to change their types to the new longer field types.
- there is critical problem in this part
when user update the integer and double both get error not update or upload
- Python function - error while creating /...
I have been trying to figure it out myself for the last 2 days. I have self-hosted appwrite instance, and I am running python 3.12 function. It works great up t...