Hi, I have a sentence MYSQL
"update users set users.propertysites = case when users.propertysites = '' then ',41,42,' else CONCAT(users.propertysites, '41,42,') end where users.id in (211) "
I'm run it in model of phalcon:
$getSQL = "update MyApp\Model\Users users set users.propertysites = case when users.propertysites = '' then ',41,42,' else CONCAT(users.propertysites, '41,42,') end where users.id in (211) ";
$query = $this -> modelsManager -> createQuery($getSQL);
return $query -> execute();
I receve error: syntax CASE
Please help Excute sentence query complex mysql in phalcon. thanks