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 / lookup error for datab...
Power Apps
Answered

lookup error for database data source

(0) ShareShare
ReportReport
Posted on by 24

hello,

 

when I try to use lookup function for database data source It's work, but I getting the following formula error:

The requested operation is invalid. Server Reponse: TableName failed: Expression expected at position 34 in ColumnName eq '. inner exception: Expression exception: Expression expected at position 34 in Column name eq '. clientRequestId: 571ab9b3-d6e4-48fc-997b-c6c3c6b3561b

 

lookup formula that I am using at gallery item level as text in label:

LookUp(TableName, ColumnName = ThisItem.ColumnName).SomeOtherColumnName

 

do you have any idea what could be a reason for such a error?

 

Best Regards

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

    @jacob_ 

    You might consider a conditional statement such as:

    If(!IsBlank(ThisItem.ColumnName), 
     LookUp(TableName, ColumnName = ThisItem.ColumnName, SomeOtherColumnName)
    )
  • jacob_ Profile Picture
    24 on at

    that's correct first record of gallery do not have value for this attribute, what is the best practice to handle such a records via lookup function? 

     

    thank you!!

  • Verified answer
    RandyHayes Profile Picture
    76,297 Super User 2024 Season 1 on at

    @jacob_ 

    From the error message, it appears that ThisItem.ColumnName has no value.

    What is the context of your Lookup - form, gallery, etc?

  • WarrenBelz Profile Picture
    153,508 Most Valuable Professional on at

    @jacob_ ,

    I will tag colleague @RandyHayes here - I do not use SQL

  • jacob_ Profile Picture
    24 on at

    azure sql (serverless), moreover  ThisItem.ColumnName (whole number) is passed from Power BI

  • WarrenBelz Profile Picture
    153,508 Most Valuable Professional on at

    @jacob_ ,

    What is your data source (SQL)?

  • jacob_ Profile Picture
    24 on at

    well at the datasource level ColumnName data type is int, but OtherColumnName is varchar(3000)

  • WarrenBelz Profile Picture
    153,508 Most Valuable Professional on at

    Hi @jacob_ ,

    What type of fields are ColumnName and OtherColumnName?

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
Kalathiya Profile Picture

Kalathiya 427

#2
WarrenBelz Profile Picture

WarrenBelz 360 Most Valuable Professional

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 336 Super User 2025 Season 2

Last 30 days Overall leaderboard