I'm not an SSIS SSRS guy but if you just need the t-sql to get yesterday 5:00am to Today 4:59:59am then you can use this:select dateadd(day, datediff(day, 1, getdate()), '5:00:00.000') as FromDate ,dateadd(day, datediff(day, 0, getdate()), '5:00:00.000') as ToDateoutput:FromDate ToDate----------------------- -----------------------2009-03-24 05:00:00.000 2009-03-25 05:00:00.000Then you can say in your sql code:WHERE <yourDateColumn> >= FromDateAND <yourDateColumn> < ToDate
Be One with the OptimizerTG