Lets simplify your query a little:
Sql = "select s.Name,s.DOB,s.Mobileno,s.Weddingday from BirthDayWish s where s.Active <> 'D'";
Sql = Sql + " and (month(DOB) = month('"+ Convert.ToDateTime(CurDate) + "') and day(DOB) = day ('" + Convert.ToDateTime(CurDate) + "'))";
Sql = Sql + " or (month(Weddingday) = month('" + Convert.ToDateTime(CurDate) + "') and day(Weddingday) = day ('" + Convert.ToDateTime(CurDate) + "'))";
Becomes
select s.Name,s.DOB,s.Mobileno,s.Weddingday from BirthDayWish s where s.Active <> 'D'
and (month(DOB) = month('2013-01-01') and day(DOB) = day ('2013-01-01'))
or (month(Weddingday) = month('2013-01-01') and day(Weddingday) = day ('2013-01-01'))
Which becomes:
select s.Name,s.DOB,s.Mobileno,s.Weddingday from BirthDayWish s
where s.Active <> 'D'
and (month(DOB) = 1 and day(DOB) = 1)
or (month(Weddingday) = 1 and day(Weddingday) = 1)
And to make it even easier, I'll rewrite it as:
select s.Name,s.DOB,s.Mobileno,s.Weddingday from BirthDayWish s
where activeEqualsD and DOBMatches or WeddingdayMatches
Now, AND has precedence over OR, so that will be evaluated as:
select s.Name,s.DOB,s.Mobileno,s.Weddingday from BirthDayWish s
where (activeEqualsD and DOBMatches) or WeddingdayMatches
Which probably isn't what you want!
I'm not exactly sure what you are trying to do here - since the statement will return data based on either condition and I have no idea about your code which uses the data - but I strongly suggest that you work out exactly what you want in a similar way to the above, reversed, and use brackets to ensure execution order and priority.