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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / AddColumns function di...
Power Apps
Unanswered

AddColumns function display error

(0) ShareShare
ReportReport
Posted on by 308

Hi PowerApps community,

 

I am trying to add a lookup column in my galley list. However, I have tried insert the code in my gallery and in a button but I keep getting the same error:

 

First attempt:

AddColumns(Filter(
 colOrders,
 IsBlank(cbVendors.Selected.ID) || IsEmpty(cbVendors.SelectedItems) || Supplier_ID = cbVendors.Selected.ID,
 IsBlank(txtOrderQuote) || Quote_Num = txtOrderQuote.Text
),"Client_ID",LookUp(colParentOrders,Merge_ID=Merge_ID,Client_ID))

 

Second attempt:

Filter(
 AddColumns(colOrders,"Client_ID",LookUp(colParentOrders,Merge_ID=Merge_ID,Client_ID)),
 IsBlank(cbVendors.Selected.ID) || IsEmpty(cbVendors.SelectedItems) || Supplier_ID = cbVendors.Selected.ID)

 

Merge_ID is in the colOrders and the colParentOrders.

 

Any help will be much appreciated.

Categories:
I have the same question (0)
  • Verified answer
    RandyHayes Profile Picture
    76,297 Super User 2024 Season 1 on at

    @JB0007 

    Please consider changing your Formula to the following:

    Filter(
     AddColumns(colOrders As _item,
     "Client_ID", LookUp(colParentOrders, Merge_ID = _item.Merge_ID, Client_ID)
     ),
     IsBlank(cbVendors.Selected.ID) || Supplier_ID = cbVendors.Selected.ID
    )

    The IsEmpty in your formula is not relevant.

    Your LookUp needs to have which Merge_ID you want to match.  In the above, the colOrder is given a reference name of _item and used in the lookup formula.

     

    I hope this is helpful for you.

  • JB0007 Profile Picture
    308 on at

    Awesome Randy,

     

    Thank very much!

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 796 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 327 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard