I have a Calendar from which I need to pick a date so when a date is picked, the query should show all the data for that date & also for the next 7 days.
My current Query is as below, but it only shows the data for the date that’s been picked.
SELECT MailDate, Status, JobNo
FROM Table_1
WHERE MailDate=@MailDate
Please help me out with this. I’m using SQL SERVER 2008
Select MailDate, Status, JobNo FROM Table_1 WHERE MailDate BETWEEN @MailDate AND @MailDate + 7May or may not work, you didn’t tell us what sql engine we’re talking about.