Rank 2: Process
$result = $databases->listDocuments($databaseId, $collectionId);
$data = json_encode($result);
here i want to all those documents, as data will too big and anonymous amount(1k or 10k...),is there query to achieve this?
Votes
0
Replies
11
Participants
Unknown
Messages
12
Rank 2: Process
$result = $databases->listDocuments($databaseId, $collectionId);
$data = json_encode($result);
here i want to all those documents, as data will too big and anonymous amount(1k or 10k...),is there query to achieve this?
Rank 4: Virtual Machine
Check Queries.limit on doc
Rank 2: Process
thanks,but i didn't find any doc about query in PHP
Rank 4: Virtual Machine
Rank 2: Process
yes,i was following this doc, but how to attach query with them?$params = [
'limit' => 5000,
];
$result = $databases->listDocuments($databaseId, $collectionId, $params);
$data = json_encode($result); (is this the right way to do this?)
Rank 4: Virtual Machine
Check this : https://github.com/appwrite/sdk-for-php/issues/12
Rank 2: Process
i really appreciate your help,but what if i don't want to use any limit..bcz you we will never know how much data is there?so should i leave limit value empty?
Rank 4: Virtual Machine
For what I know, you can't query "unlimited" documents. If you want to query all, you can call listDocument once, with limit(0), it'll give you total document, and call again listDocument with limit = total
Rank 4: Virtual Machine
If I remember, max limit is 5000
Rank 4: Virtual Machine
Or you can paginate, ofc
Rank 2: Process
[Solved]List all documents without limit, as my data is too big.
Admin
[SOLVED] List all documents without limit, as my data is too big.