Answer the question
In order to leave comments, you need to log in
sql query not running in php, how to fix error?
There is a sql query in php:
$sql 'UPDATE `_spi`
SET `w_st`=`w_t`+`w_s`+`w_z`+`w_p`
CASE WHEN `p_m` = 'IV'
THEN `w_t`+`w_s`
ELSE 0
END';
PHP Parse error: syntax error, unexpected 'IV' (T_STRING)
Answer the question
In order to leave comments, you need to log in
$sql = "UPDATE `_spi`
SET `w_st`=`w_t`+`w_s`+`w_z`+`w_p`
CASE WHEN `p_m` = 'IV'
THEN `w_t`+`w_s`
ELSE 0
END";
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question