cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
powerapps890
Post Prodigy
Post Prodigy

Get text value from another data source outside of the gallery

I am trying to do a lookup in my gallery to a different data source to display the value "works" or fails" from a column LookUp(UATListData, Checkbox = ThisItem.C8, ID = ThisItem.C1 & Name_=varUser). The column is called checkbox in the other datasource outside of the gallery datasource. It has to be specific to each person using the app and I tried to lookup using each items specifc ID number. How can I pull the text value from the checkbox column? the gallery is where the label will be the other datasource I want to lookup to is connected to a form.

3 REPLIES 3
Drrickryp
Super User
Super User

@powerapps890 

Your Lookup formula makes no sense.  In order to do the lookup, there has to be a common field in both lists. Ideally it could be the ID field from the Parent list to a field called parentID in the second list.  Looking up somefield in the second list from a gallery of items in the first list, the syntax would be 

 

Lookup(List2,parentID=ThisItem.ID,somefield)

for a label in the gallery. 

 

 

I tried this and got invalid string query. Is parent ID in the gallery list or the form list? I just want the text field column from the form to be displayed for each item on the gallery. Could I use the title for this? They both have the same title. @Drrickryp 

Drrickryp
Super User
Super User

@powerapps890 

You need to use a common field between the two lists for the lookup.  If the name of the field is the same in both lists, then you may need to disambiguate them for the lookup.  For the sake of an example, I will use List1 and List2.  Lets say the gallery contains List1 and the lookup is to List2 and someother field is a field in list2.

AddColumns(
            List1,"someotherfield",Lookup(
                                           List2,title=ThisItem.Title,someotherfield
                                   )
)

 

Helpful resources

Announcements
Power Apps News & Annoucements carousel

Power Apps News & Announcements

Keep up to date with current events and community announcements in the Power Apps community.

Community Call Conversations

Introducing the Community Calls Conversations

A great place where you can stay up to date with community calls and interact with the speakers.

Power Apps Community Blog Carousel

Power Apps Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Top Kudoed Authors
Users online (2,233)