In this type of code,
AND Orders.ShipDate >= DATEADD(Day, Datediff(Day,0, GetDate() -6), 0)
It supposed to pull records with the date 6 days ago, until today. How can I make it pull records from 7 days ago until yesterday?
I know changing -6
to -7
will pull records from 7 days ago, but which variable is the end of the date span so I can change it to -1
?