How to use map() and match a timeline.from column data by formatDate() to YYYY-MM

Hi Makers,

I am currently working on Monday automation and I have a part where I aggregated the data and I wish to do a filter before going to next module. Ideally, my filter should use mpa() to loop through the array and format the date to YYYY-MM from YYYY-MM-DD format so I can just compare based on the year and month. However, the formatDate() does not seem working with map(), would like to know how can I make this happen?

Here is my scenario and specific filter:


Thank you!

Hi @Wing

map() will result a array value, at the same time formateDate will not accept they array.

To solve issue, please use get() after map() to get the value from array.

MSquare Support
Visit us here
Youtube Channel

Hi @Msquare_Automation ,

Thanks for your reply, however this get() always getting the first object in the array only. Hence, I did a workaround to make my scenario happens.

I aggregate to JSON with the object data that I will be using after this module, and filter if the specific match in the JSON string. If yes, parse the JSON and continue with the filter to populate with the specific data set.

Thank you!

3 Likes

Hello @Wing :wave:,

Just wanted to jump in and congratulate you on solving this one. Iā€™m glad to see that you got the ball rolling. :+1:

Thank you very much for getting back to us and sharing your solution with us. We honestly appreciate that you kept us in mind and marked the problem as solved so other users can easily find it while having similar issues. :blush:

1 Like