web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Comparing table value ...
Power Apps
Answered

Comparing table value to text value

(0) ShareShare
ReportReport
Posted on by Microsoft Employee

Hi,

I'm trying to implement write back functionality in the PBI report using a Power Apps embedded in it. The source for PBI is a SP Excel. 

Upon selecting an item in the gallery view the records are not getting reflected in the Edit Form screen. The condition I have used is given below. Please help me in figuring this out
LookUp(Table1,'Supplier ID',Gallery1.Selected.'Supplier ID'). 

Any post regarding this would be appreciated.

Thanks in advance.

Categories:
I have the same question (0)
  • WarrenBelz Profile Picture
    155,983 Most Valuable Professional on at

    Hi @Anonymous ,

    I think you need

    LookUp(
     Table1,
     'Supplier ID' = Gallery1.Selected.'Supplier ID'
    )

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

    Visit my blog Practical Power Apps

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hi @WarrenBelz ,

    Thanks for your solution.
     It seems now the error is due to server response.

    Thirunarayanan_0-1654845608954.png

     

  • WarrenBelz Profile Picture
    155,983 Most Valuable Professional on at

    Hi @Anonymous ,

    I cannot see your data and can only rely on the values you posted. The code I provided is valid if the field 'Supplier ID' is in both Gallery1 and Table1 and is either numeric or Text. What type of field is it ?

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    It's a numeric data type.

  • WarrenBelz Profile Picture
    155,983 Most Valuable Professional on at

    @Anonymous ,

    From the error it appears to be Text in the Gallery, so try this

    LookUp(
     Table1,
     'Supplier ID' = Value(Gallery1.Selected.'Supplier ID')
    )

    You simply need to match the two items in both value and data type.

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

    Visit my blog Practical Power Apps

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

     

    @WarrenBelz ,

    I tried the above solution as well as various combinations but still the same. 

  • WarrenBelz Profile Picture
    155,983 Most Valuable Professional on at

    @Anonymous ,

    You simply need to match the data types - If Supplier ID is numeric, then assuming the same field is available in Gallery 1, then one of

    'Supplier ID' = Value(Gallery1.Selected.'Supplier ID')

    or

    'Supplier ID' = Gallery1.Selected.'Supplier ID'

    has to work. Can you please check your data as I can only respond to the information you have posted.

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    @WarrenBelz ,

    Sorry for the pestering you in this.

    Let me explain the process and what I have done. 

    I have created an excel file and converted it into Table and stored in a SharePoint Folder.


    Thirunarayanan_0-1654951014109.png

     

    Next, I've created a PBI report by fetching data from the SharePoint Folder and published the report in a workspace. 

    In the PBI service I have created an Power Apps visuals containing the  Req No. and Item fields to implement the write back functionality (i.e. Perform CRUD operation on the source file).

     

    In the Power Apps I've imported the source file via Excel Online (Business). 
    Note: All the columns are are text datatype.

     

    Please refer the below image for the Power Apps I'm trying to create. Highlighted formula in the Edit form is causing an issue.

    My objective is to display the data selected data in the gallery into the edit form

    Thirunarayanan_1-1654951419845.png


    Thank you @WarrenBelz , for being so patient and helpful. Let me know if you need anything else.

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    @WarrenBelz , the error I'm receiving is given below.

    Thirunarayanan_2-1654951846447.png

     

  • Verified answer
    WarrenBelz Profile Picture
    155,983 Most Valuable Professional on at

    @Anonymous 

    Are you saying now it is Text (not numeric as previously noted). You have not stated the Items of Gallery1, but assuming it is based on the Table, then 

    'Supplier ID' = Gallery1.Selected.'Supplier ID'

    is correct. This is the most basic of data matches and simply should work if both values are of the same data type. Also when you noted importing the data from Excel, is this into a SharePoint List (Table1). If so, go to the List Settings, select the 'Supplier ID' column and look at the end of the URL at the top to see what the actual field name is.

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

    Visit my blog Practical Power Apps

     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 320 Most Valuable Professional

#2
11manish Profile Picture

11manish 210

#3
Valantis Profile Picture

Valantis 167

Last 30 days Overall leaderboard