


I am looking to run a query each month to pull data the month prior e.g if I were to run in Feb, it would pull Jan's data
The '1 months ago' option is not useful as this will not be run at the beginning of the month
Is there a way to pull just the prior month in whole?
Solved! Go to Solution.
Views
Replies
Total Likes
Hi @NialC ,
There are number of ways through which you can achieve this:
1) Schedule your workflow to run on 1st of every month and then use a month ago in the query.
2) In Query activity, do
Month(@contactDate) = Month(GetDate) -1 and
Year(@contactDate)=Year(GetDate)
Thanks,
Jyoti
Hi @NialC ,
There are number of ways through which you can achieve this:
1) Schedule your workflow to run on 1st of every month and then use a month ago in the query.
2) In Query activity, do
Month(@contactDate) = Month(GetDate) -1 and
Year(@contactDate)=Year(GetDate)
Thanks,
Jyoti