I have an SSIS package that queries data from a view using an SQL Command.
The SQL Command looks something like this:
SELECT from myView WHERE dateEntered >= GetDate() AND dateEntered < GetDate() + 1
Now I want to be able to specify the start and end dates such that the query behaves as:
SELECT from myView WHERE dateEntered >= startDate AND dateEntered < endDate
However, if start and end dates are not provided I need to use today's date and today's date + 1
What would be the best way to do this in an SSIS Package?
I can't change the view so it has to be done off the view or using variables in the SSIS. I'm not too familiar with SSIS and not sure if there is something in the toolbox that would let me process a date variable and then use it in the SQL Command?