I am trying to add a filter to look back 30 days and 180 forward, this giving a really hard time, and I tried everything possible to make this work, but I am stumped and could not figure it out. Can anybody please tell me, how to make this work? I am trying every single option online for a week now. This date filter killing me.
What I am trying to Filter (createdDateTime)
What I tried so far
FormatDateTime('createdDateTime', 'yyyy-mm-dd') ge formatDateTime(addDays(utcNow(),-30),'yyyy-MM-dd')
AND formatDateTime(addDays(utcNow(), 180),'yyyy-MM-dd')
FormatDateTime(triggerBody()?['createdDateTime'],'yyyy-MM-dd') ge formatDateTime(addDays(utcNow(),-30),'yyyy-MM-dd')
Getting another error for above "One or more fields provided is of type 'Null', a different type is expected."
Thank you so much
Try something like this:
From Date:
formatDateTime(triggerBody()?['From'],'yyyy-MM-dd')
To Date:
formatDateTime(triggerBody()?['To'],'yyyy-MM-dd')