Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SQL

mysql case when or

SELECT
    CASE 
        WHEN
            column IS NULL OR another_column = 1
        THEN
            'yes' 
        ELSE
            'no' 
    END AS 'MyData'
FROM
    table_name;
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #mysql #case
ADD COMMENT
Topic
Name
9+9 =