Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Load *;
SQL Select *
from DM.Da
Where monthstart(CreatedDate,'YYYY-MM-DD') >= Date(monthstart(dateadd(month,-10,Today(),'YYYY-MM-DD'));
this statement throws an error, monthstart is not avaible in sql server. How can i load data for past 10 months ?
Yes I know.. I don't have a running SQL database to make the tests for you..
Will something like this work?
Load *;
SQL Select *
from DM.Da
Where CreatedDate > DATEADD(mm, DATEDIFF(mm, 0,
DATEADD(month,-10,GetDate())),
0)
Hi Baarathi - I see you are in capable hands. Thanks for tagging me.