• KTTHOOL,

    Please don't get frustrated or upset here. What we've asked for is you to explain what isn't working for you. We feel, a few of us, that you haven't presented a problem. You've stated something, and given code, but not explained what isn't working for you.

    You can attack this two ways. One is to calculate the dates forward, meaning determine what is 15 days out (start date/end date) and 30 days out, or you can build a function to compare the dob's to the current date.

    Be aware of time. Today is 3/30/09. It's 8:43am. so 15 days out is

    - 4/14/09 00:00:00

    - 4/14/09 23:59:59

    The time 15 days out with getdate is 4/14/09 8:43am

    When you calculate the dates, you might want to remove the times to handle this.

    DECLARE @currdate datetime, @firstdate datetime

    select @currdate = '3/15/09 8:43am'

    select @firstdate = cast(

    cast( year(@currdate) as varchar(4)) + '/' +

    cast( month(@currdate) as varchar(2)) + '/' +

    cast( day(@currdate) as varchar(2))

    as datetime)

    select @currdate, @firstdate

    In terms of posting a question, please tell us the issue, You never made that clear. Don't give us code and expect that we will understand what you are thinking.