Reputation: 597
As per the query, the row from 1 to 11 should be deleted, but didn't. What is the reason?
select * from tblPerson;
delete from tblPerson where Age = NULL
Upvotes: 1
Views: 804
Reputation: 1242
This should work
DELETE FROM tblPerson WHERE Age IS NULL
Age IS NULL
checks whether Age is a NULL value.
Age = NULL
is checking whether Age is equal to NULL which will never be true.
Upvotes: 4