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 Apps
Unanswered

LookUP

(0) ShareShare
ReportReport
Posted on by 86

Hi all 
While Iam using LookUp Getting Slowness in the app So In place of LookUp Is any function is there work like as a LookUp If any knows Please advise me


Thanks in advance

Categories:
  • vaubeee Profile Picture
    533 on at

    Hi @Sairam_pera  would be good to have your actual code. 

    Maybe this already helps Filter, Search, and LookUp functions in Power Apps (contains video) - Power Platform | Microsoft Learn

     

    ------------------------------------------------------------------------------------------------------------------------------
    If I have answered your question, please mark your post as Solved. Remember, you can accept more than one post as a solution.

    If you like my response, please give it a Thumbs Up.

  • Rajkumar_M Profile Picture
    3,747 Moderator on at

    Hi @Sairam_pera 

     

    You can use Filter() function alternative for LookUp function.

     

    Refer link : PowerApps LookUp vs Filter vs Search Functions by Examples (zeitgeistcode.com)

     

    Thanks!

     

    If my response has been helpful in resolving your issue, I kindly request that you consider clicking "Accept as solution" and "giving it a thumbs up" as a token of appreciation.

  • Sairam_pera Profile Picture
    86 on at

    LookUp(PatientDocuments, CaseId=Lcase And DocumentCode=Attachments[@Code]).DateOfUpload For this Code Could you Please Give by using Search Function

    Thanks in advance

  • Rajkumar_M Profile Picture
    3,747 Moderator on at

    Hi @Sairam_pera 

     

    You can use the Filter() function to find the record that satisfies the given conditions.

     

    First(
    Filter(
    PatientDocuments,
    CaseId = Lcase && DocumentCode = Attachments[@Code]
    )
    ).DateOfUpload

     

    Thanks!

     

    If my response has been helpful in resolving your issue, I kindly request that you consider clicking "Accept as solution" and "giving it a thumbs up" as a token of appreciation.

  • Sairam_pera Profile Picture
    86 on at

    Yes, I used this before Getting Performance Issue for this code also, That's why Iam asking with Search

    Thank you


  • timl Profile Picture
    37,355 Super User 2026 Season 2 on at

    @Sairam_pera 

    IMO, Search and Filter will not provide any performance benefit over LookUp.

    Filter and Search return multiple records whereas LookUp is specifically designed to return a single record. Therefore, LookUp will be the more performant of all these functions.

     

    Also, if you're using SharePoint, Search is not delegable. Therefore, Search will not return the correct record if the data source contains more than 2000 rows.

     

    The typical reason for slow performance is that the data source contains many columns which will slow down data retrival.

     

    If you're using SharePoint or SQL, you can try indexing the DocumentCode and CaseId columns. That might help to improve the retrival time from within the data source.

  • Sairam_pera Profile Picture
    86 on at

    Yes, I am using SQL and also I given indexes for those two columns
    OnVisible:
    ClearCollect(CombinedData,
    AddColumns(
    Attachments,
    "DateOfUpload", LookUp(PatientDocuments, CaseId=Lcase And DocumentCode=Attachments[@Code]).DateOfUpload,
    "DocumentStatus",LookUp(PatientDocuments, CaseId=Lcase And DocumentCode=Attachments[@Code]).DocumenStatus
    )
    )
    So takes time to display Data

    Thanks in advance

     

  • timl Profile Picture
    37,355 Super User 2026 Season 2 on at

    @Sairam_pera 

    The problem here isn't the call the LookUp - it's because you're calling it twice for each row in Attachments. So if the Attachments table contains 100 rows, that will result in 200 calls to Lookup on the PatientDocuments table.

     

    The only way to resolve this to not to call LookUp, but to instead create a view in SQL Server that joins the Attachments and PatientDocuments tables. If you then connect to this view from Power Apps, that will resolve the performance problem.

  • Sairam_pera Profile Picture
    86 on at

    Based on Caseid CombinedData as Shown if caseid was Changed then CombinedData has Changed So is it Possible in View

    thanks

     

  • timl Profile Picture
    37,355 Super User 2026 Season 2 on at

    A SQL View will return the latest version of the data from the database. So long as the modified caseid value is saved to SQL Server, the view will return the correct data.

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

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 342 Super User 2026 Season 2

#2
M Bilal Khan Profile Picture

M Bilal Khan 258

#3
Mohsin Ali Profile Picture

Mohsin Ali 231

Last 30 days Overall leaderboard