cancel
Showing results forย 
Search instead forย 
Did you mean:ย 

How to reference a list item in a data pill expression

Waldy
Deputy Chef III
Deputy Chef III

I'm trying to reference the ID property of a list item in a data pill expression.  I could do a for each and loop through to get the relevant item, but I guess there must be a way to do this via the expression.

Screenshot 2025-04-16 090807.png

This expression gives me an error when I try to test the recipe.

1 ACCEPTED SOLUTION

Bhagya_pola
Deputy Chef II
Deputy Chef II

Hello @Waldy 
you can give it a try using pluck formula
for example:

This is my json:


 Screenshot 2025-04-16 142614.png
In the above json I'm trying to fetch the first person age using the name, here how I am doing it
Screenshot 2025-04-16 142637.png
Since I'm trying to fetch age from matching person which is Jhon and, I am using indexing to get first value in case of multiple records.
Once go through and modify this formula according to your requirement.


View solution in original post

4 REPLIES 4

Bhagya_pola
Deputy Chef II
Deputy Chef II

Hello @Waldy 
you can give it a try using pluck formula
for example:

This is my json:


 Screenshot 2025-04-16 142614.png
In the above json I'm trying to fetch the first person age using the name, here how I am doing it
Screenshot 2025-04-16 142637.png
Since I'm trying to fetch age from matching person which is Jhon and, I am using indexing to get first value in case of multiple records.
Once go through and modify this formula according to your requirement.


Thanks @Bhagya_pola, yes that worked.

gary1
Executive Chef III
Executive Chef III

The label of the data pill is often not the "API Name" which is the key need to you use in the expression. Hover over the data pill and you can see the API Name. It might just be a casing thing, like "Name" versus "name", or it might be something entirely different.

api key.jpg

Waldy
Deputy Chef III
Deputy Chef III

Thanks @gary1 , yes I needed to change to lower case