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 / Using Search function ...
Power Apps
Answered

Using Search function for searching in lookup columns

(0) ShareShare
ReportReport
Posted on by 86
 I have few lookup columns in my table , namely "PERMIT_TYPE" , "DEPARTMENT" and "PLANT". 
 
The formula i wrote is as follows , even before completing i get this error. I checked the syntax but couldn't find any solution. 
 
I have the same question (0)
  • Suggested answer
    Pacel1 Profile Picture
    79 on at
    Searching the lookup column can be problematic.
    To work around this, you can create a collection that adds the text value from the lookup field to a new column
    ClearCollect(NameOfCollection,AddColumns(WORK_PERMIT_DETAILS,YourNewColumnName,PERMIT_TYPE.'PERMIT_TYPE'))


    Then searching the collection should work correctly
     
    Search(NameOfCollection, TextInput2.Text,YourNewColumnName)
  • Verified answer
    WarrenBelz Profile Picture
    154,799 Most Valuable Professional on at
    Can you please remember to post your code in Text - saves re-typing here. The code should be something like
    Search(
       AddColumns(
          WORK_PERMIT_DETAILS,
          PermitType,
          PERMIT_TYPE.Value
       ),
       Textlnput2.Text,
       PermitType
    )
    Also as a bit of advice, SharePoint Lookup columns are mostly unnecessary with Power Apps and have the potential to cause you unwanted and unneeded complexity and restrictions - I have never used them. It is generally a better idea to get the required field items directly from the second list with Power Apps and write back to a Text column.
     
    Please click Does this answer your question 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 a Like.
    MVP (Business Applications)    Visit my blog Practical Power Apps    Buy me a coffee

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 536

#2
WarrenBelz Profile Picture

WarrenBelz 426 Most Valuable Professional

#3
Haque Profile Picture

Haque 305

Last 30 days Overall leaderboard