I have one column in my table named 'process' which is a BOOLEAN type and has a value NULL by default. When I set the values of 'process' of all rows to NULL and do the query
SELECT * FROM `tablename` WHERE `process` != 1
MySQL returns an empty result set. I also get the same result when I do
SELECT * FROM `tablename` WHERE `process` = NULL
Furthermore, when I use PHP to print out the rows like
$result = mysqli_query($conn, "SELECT * FROM log");
while ($row = mysqli_fetch_array($result, MYSQLI_ASSOC)){
if ($row['process'] != 1)
echo $row['time']." ".$row['event']."\n";
}
I don't get an empty result set. Can anyone explain to me where the problem is?
Thanks.