A webhook contains 2 complex arrays; Value, Previous Values.
Each of these contains keys for Name, id, color
I am trying to create two filters that compare the values of the ID field from both arrays
For instance if the webhook returned ID values of 1,2,3,4,5 for Values and 1,2,3,4 for Previous values, the filter would only allow 5, as the value is contained in Values, but not contained in previous values
The 2nd filter would need to do the opposite of that - only allowing those values that were in previous values but are not in values to pass. Ex. Values array contained 1,2,4,5 & Previous Values array contained 1,2,3,4,5 - the filter would only allow 3 to pass as it is contained in previous values but is not contained in values.
In the screenshot attached the example the hierarchy of the bundle.
Any help would be greatly appreciated!
1 Like
Hey @Matt_Tesdell
This does sound complex but should be totally doable in many ways. I’d point you toward using map formula to get all the ids, convert them into an array and then using deduplication formula to get unique ids.
1 Like
@Matt_Tesdell
For the 1st, just use an iterator on the value.tags array then the filter would look something like this:
For the 2nd, iterate the previousvalue.tags array and a filter like this:
Jim - The Monday Man (YouTube Channel)
Watch Our Latest Video: A monday Status Column Tip - When is “Done” really DONE?
Contact me directly here: Contact – The Monday Man
3 Likes
Hi Jim,
Thank you for the idea! I’ll give it a try and let you know if I get it to work. Seems like it should.
Hey Jim,
That worked!
Thanks so much for the help!
Best,
Matt
1 Like
So glad I read this post! I didn’t know you existed until just now @JimTheMondayMan - you just got yourself a new sub.
2 Likes
@johnematias
LOL, Thanks! Glad to hear it!
2 Likes
@johnematias
Hello Jim,
I found your answer concerning this question interesting, but for my case, it was not helpful: Filter by comparing values from 2 arrays - #3 by JimTheMondayMan
So I thought, you could also help me?
Let me show you my case:
I want to filter the contacts, who said “Yes” in the field “Rechnung”.
But the webhook gives me the information in this way:
and presents all as one “field”
I have to split it in some way and tried it with the iterator you talked about in this post. I did this like that:
But my result is this:
So I need more specific help, how I can split the fileds and filter my contacts especially concerning field with the name “Rechnung”.
The problem is, that “Rechnung” and “Datenschutz” can have the same value “Yes”.
But relevant for filtering is only the string with the name “Rechnung”.
Can you help?
Thank you very much!
Swantje
@Swantje_Gebauer
Probably best if you create a new post for this. But…
In your filter, one expression you can use to directly reference the "Rechnung” value would read something like this:
get(map(custom_fields[];value; name; Rechnung);1)
There is no need for the iterator.
Jim - The Monday Man
Column Magic - the magical columns toolbox app for monday.com
We Create Custom Solutions - Your Make or Ours
Thank you very much, but I can’t implement it right…
When I put the formula in the filter like this, it also runs through, if “Rechnung” has the value “No”.
So I think, I didn’t understand your idea correctly…
But when I ad this formula fpr creating a record in airtable first and then use the field with the result in the filter, then it works.
Now I just need to delete this field again later for the next incoming data.
So thank you very much!
Swantje
1 Like
@Swantje_Gebauer
Looks like you understood it perfectly.
1 Like