NULL to 0

From: Date: Sun, 18 Jul 2010 02:15:28 +0000
Subject: NULL to 0
Groups: php.db 
Request: Send a blank email to php-db+get-47264@lists.php.net to get a copy of this message
What modification does this query need that if either total_score or questions_answered have a value of "NULL" that it will be changed to 0 ("ZERO") Ron SELECT SUM(my_Bible_trivia_knowledge_questions_answered.score) AS total_score, my_Bible_trivia_knowledge_profile.questions_answered FROM my_Bible_trivia_knowledge_questions_answered INNER JOIN my_Bible_trivia_knowledge_profile ON my_Bible_trivia_knowledge_questions_answered.my_Bible_trivia_knowledge_profile_reference = my_Bible_trivia_knowledge_profile.reference WHERE my_Bible_trivia_knowledge_profile.ip_address = '$ip_address'

« previous php.db (#47264) next »