I'm sending json via dataloader like this:
{"person":{"name":[{"tag":"peter"},{"tag":"frank"},{"tag":"jeff"}]}}
I have the below query and as of right now I filter by exact values. But how do I search 'like' for the values this example?
php:
...
$arr = json_decode($data,true);
$name = $arr['person']['name'];
foreach($name as $t=>$tag){
$name[] = $tag['tag'];
}
$query = "SELECT name, id
FROM accounts
WHERE visible != '1'";
if ($name) {
$query.=" AND name IN ('".implode("', '", $name)."')";
}
$query.=" ORDER BY name DESC";
...