Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SQL

mysql count with if

SELECT COUNT(IF( `column` = 1, `column`, NULL)) as total
Source by modern-sql.com #
 
PREVIOUS NEXT
Tagged: #mysql #count
ADD COMMENT
Topic
Name
8+9 =