Stupid Question I'm Sure - Can you Query based on NULL

Questions about the MySQL, PostgreSQL, and most other databases, as well as using it with PHP can be asked here.

Moderator: General Moderators

Post Reply
rbc
Forum Newbie
Posts: 22
Joined: Tue Sep 02, 2008 6:00 pm

Stupid Question I'm Sure - Can you Query based on NULL

Post by rbc »

I have a situation that I'd like to search a DB table to find those that have a NULL value.

Code: Select all

SELECT * FROM table_name WHERE columnA=NULL
Is something like this doable? If not, is there a work around? Thanks!
rbc
Forum Newbie
Posts: 22
Joined: Tue Sep 02, 2008 6:00 pm

Re: Stupid Question I'm Sure - Can you Query based on NULL

Post by rbc »

Totally stupid. Knew it was. Just use IS NULL. Please delete this useless post.
Post Reply