Categories: Snippets

How do I check if a column is empty or null in mysql

SELECT * FROM table WHERE some_col IS NULL OR some_col = '';

 

Recent Posts

Generate Slug URL in MySQL

A slug is a short name using human-readable keywords to identify a web page. For…

7 years ago

How to use SQL LIKE condition with multiple values in PostgreSQL?

[crayon-68bb1b12d4b3a944786941/]  

7 years ago

SELECT Null

[crayon-68bb1b12d507f337748188/]  

7 years ago

ALTER Column SET NOT NULL – pgSQL

[crayon-68bb1b12d6355202636823/]  

7 years ago

ADD new Column – pgSQL

[crayon-68bb1b12d659f992331640/] [crayon-68bb1b12d65a6613108894/]  

7 years ago