I need to retrieve columns of a row that one of its data types is empty. Extra VARCHAR Extra has nothing in it
Show those with empty extra column
Select * FROM Items WHERE Extra ?????
What should be the condition ?
Check whether it is null or empty string.
Select * FROM Items WHERE Extra IS NULL OR Extra = ''
If empty means "" or empty string then:
select * from items where extra="";
The length of empty string is zero/0 .
If empty means NULL then:
select * from items where extra is NULL;
The length of NULL is NULL.
If you want to read more, you can read these:
If you by empty mean NULL...
Select * FROM Items WHERE Extra IS NULL
Select empty varchar
fields, with either an empty string or NULL in it:
SELECT * FROM `Items` WHERE `Extra` < 1;