SQLTeam.com | Weblogs | Forums

Birthdays remaining


I’m new to transact SQL and currently going through a tutorial that is just a birthday list of employees. Would like to write a stored procedure for a list of people that I have remaining to tract down their birthdays. I have written the basic stored procedure.
go---begins a new batch
create proc spbirthdaysrem

select firstname,

from dbo.[1Family]
where birthdays=[ISNULL]

First question is this possible or due I need to put something else besides the words (NULL) in the birthday rows where I do not have the information, any help would be helpful.


The correct syntax is

where birthdays IS NULL


See @JamesK for correction.
Yes, IMO using null instead of a placeholder lets you have some flexibility in how you work with the column. If you put a placeholder in then you will need to check for that when working with the data.