Closed itmeicn closed 2 years ago
What you have here is the first page of result.
You have 10 documents (the default page size of RediSearch is 10
).
For example you can get the 10 documents:
$items = $results->current();
dump($items); // That will be your documents
$first = reset($items);
dump($first->getFieldValue('name')); // will the content of the field 'name' of the document
Or read the next page of documents:
$results->next();
$items = $results->current();
dump($items); // That will be your next 10 documents
By default, RediSearch will return the complete Redis document, even if there are fields that are not indexed
This is (hopefully) all explained in this documentation: https://github.com/MacFJA/php-redisearch/blob/main/docs/UsingResult.md
ths