This will select all rows where some_col is NULL or '' (empty string)

SELECT * FROM table WHERE some_col IS NULL OR some_col = '';
Answer from maček on Stack Overflow
🌐
W3Schools
w3schools.com › sql › sql_null_values.asp
SQL NULL Values - IS NULL and IS NOT NULL
SELECT column_names FROM table_name WHERE column_name IS NOT NULL; Below is a selection from the Customers table used in the examples: The IS NULL operator is used to test for empty values (NULL values).
🌐
Baeldung
baeldung.com › home › sql queries › find null or empty values in sql
Find Null or Empty Values in SQL Baeldung on SQL
August 20, 2025 - The COALESCE function in SQL returns the first non-NULL value from a list of arguments. COALESCE(code, ”) returns the value of the column code if it is not NULL. Otherwise, it returns an empty string.
🌐
Quora
quora.com › How-do-you-check-if-a-column-is-blank-in-SQL
How to check if a column is blank in SQL - Quora
Answer (1 of 3): SELECT * FROM table_name WHERE column_name IS NULL; Or, SELECT * FROM table_name WHERE column_name IS NULL AND column_name LIKE '””; (Note: put begining and ending quotes without any text/ space in 2nd Query.
🌐
Oracle Tutorial
oracletutorial.com › home › oracle basics › oracle is null operator
Oracle IS NULL Operator
April 27, 2025 - SELECT * FROM orders WHERE salesman_id IS NOT NULL ORDER BY order_date DESC;Code language: SQL (Structured Query Language) (sql) ... The IS NULL returns true if a value is null or false otherwise.
Find elsewhere
🌐
Red Gate Software
red-gate.com › home › checking for null with oracle sql
Checking for NULL with Oracle SQL - Simple Talk
July 14, 2021 - The LNNVL function is used in the WHERE clause of an SQL statement when one of the operands may contain a NULL value. The function returns TRUE is the result of the condition is FALSE and FALSE is the result of the condition is TRUE or UNKNOWN.
🌐
Dataedo
dataedo.com › kb › query › oracle › check-column-nullable
Check if is column nullable in Oracle database - Oracle Data Dictionary Queries
Article for: Oracle database ▾ SQL Server Azure SQL Database Snowflake Amazon Redshift IBM Db2 Teradata Vertica PostgreSQL MySQL MariaDB · Query below checks nullability attribute for the column of tables and views in specified schema.
🌐
Reddit
reddit.com › r/sqlserver › counting rows where all columns are either null or empty in the row?
r/SQLServer on Reddit: Counting rows where ALL columns are either null or empty in the row?
September 26, 2024 -

I'd rather not write a bunch of AND clauses, so is there a quick, efficient way to do this?

I'm importing some data with 10 fields into a SQL Server from a CSV file. Occasionally this file has null/empty values across all the cells/columns.

What I'd like to do is just write one relatively short sql statement to simply count (at first) all these rows. I'd rather do it without doing something like:

...and (column1 is null or column1 = '')
...and (column2 is null or column2 = '')

etc...

Is there a good way to do this, or am I stuck with the above?

🌐
Oracle
docs.oracle.com › cd › B12037_01 › server.101 › b10759 › conditions013.htm
IS EMPTY
Use the IS [NOT] EMPTY conditions to test whether a specified nested table is empty, regardless whether any elements of the collection are NULL. is_empty_conditions::= Description of the illustration is_empty_conditions.gif · The condition returns a boolean value: TRUE for an IS EMPTY condition ...
🌐
Oracle
docs.oracle.com › cd › E40518_01 › server.761 › es_eql › src › reql_sets_is_empty.html
IS_EMPTY and IS_NOT_EMPTY functions
The IS EMPTY function provides an alternative syntax to IS_EMPTY and also returns TRUE if that set is empty.
🌐
Hightouch
hightouch.com › sql-dictionary › sql-is-null
SQL IS NULL - Syntax, Use Cases, and Examples | Hightouch
December 29, 2023 - SELECT columns FROM table_name WHERE column_name IS NULL; columns: The columns you want to retrieve in the query. table_name: The name of the table containing the data. column_name: The name of the column you want to filter based on whether ...
🌐
Quora
quora.com › What-is-the-standard-SQL-query-for-checking-null-or-empty-strings
What is the standard SQL query for checking null or empty strings? - Quora
Answer (1 of 2): In standard SQL, you can use the [code ]IS NULL[/code] predicate to check if a value is [code ]NULL[/code]. To check for empty strings, you can use the [code ]IS NULL[/code] predicate along with the [code ]LENGTH[/code] function ...
🌐
GeeksforGeeks
geeksforgeeks.org › sql server › how-to-check-a-column-is-empty-or-null-in-sql-server
How to Check a Column is Empty or Null in SQL Server - GeeksforGeeks
January 31, 2024 - In this article let us discuss in detail, how to check if a column is Empty or NULL in SQL Server, with examples and different methods.
🌐
Blogger
javarevisited.blogspot.com › 2017 › 01 › how-to-check-for-null-values-in-sql.html
How to check for Null in SQL Query? IS NULL Example Tutorial
SELECT * FROM #temp WHERE id IS NOT NULL id 1 2 That's all about the right way to check for NULL values in the WHERE clause in the SQL query. Don't use = or != operator to compare values if your column allows NULLs, it may not return what you expect because comparing NULL with anything else ...
🌐
Coginiti
coginiti.co › home › beginner › sql is null
What is the IS NULL Operator in SQL? - Coginiti
September 25, 2023 - In addition to the IS NULL operator, SQL also provides the IS NOT NULL operator, which is used to test for non-NULL values in a column. ... As a result, you would see the rows that are not empty or do not have NULL values.