I have a error in my SQL statement. I am using NULL in my command and I guess thats the problem, but I am not sure. So what am I doing wrong here ?
Code:
function run()
{
$sql = "UPDATE %%EVENT%% SET lock = NULL WHERE 'lock' IS NOT NULL";
Database::get()->update($sql);
}
Error:
USER ERROR: "SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'lock = NULL WHERE 'lock' IS NOT NULL' at line 1