php-rql
php-rql copied to clipboard
Question for filter/search on nested properties
Hi,
I'm trying to do a search/filter on nested properties using the library but can't figure it out. Any good example for something like this where I want to search for "Joe". Thanks!!!
[
'id' => 123,
'customer' => [
'name' => Joe
]
]
+1
I too, have been trying, and failing to find a function that pulls it off. You can do something like this, but you're stuck with only a subset of the data since your filter is limited to the lowest point in the tree.
$cursor = r\table("mytable")->getField('customer')->filter(array('name' => 'joe'))->run($conn);
@danielmewes I've asked for help on this in the rethinkdb php slack channel as well. Is this even possible with the library?