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

error in formula

(0) ShareShare
ReportReport
Posted on by 431

Hi Team, 

I cannot seem to get my formula to work.

 

The code looks up the Serial Number and then should produce a result. I am using Distinct or Filter, but none seem to work?

 

Formula.PNG

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

    Hi @JerryH ,

     I assume that both 'Meter Type' and 'Meter Serial Number' are Single Line of Text fields? If so the only thing I can see is that you should be using .Selected as .SelectedText is deprecated.

    Distinct(
     Filter(
     Table1_2,
     'Meter Serial Number' = Dropdown1.Selected.Result
     ),
     'Meter 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.

  • JerryH Profile Picture
    431 on at

    Hi WarrenBelz
    Humbled to have a response from you 🙂

    I still have the same error. Please see datasource snip and code.

    v1.PNGExcel.PNG

  • powercorner Profile Picture
    477 on at

    Hey @JerryH ,

     

    I tried to build your scenario in a test and I couldnt see any difference, except of the "Result". Have you tried Value instead of result of your dropdown?

    powercorner_0-1633596067394.png

     

    I have built a simple table: 

    powercorner_1-1633596112668.png

    And the dropdown is also set to "DropDownSample" and contains Values (1,2,3)

    Maybe this helps?

     

    With regards
    Kevin



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

    Hi @JerryH ,

    Assuming that your Drop-down is a Distinct Filter (it would show an error if not), then .Result is the correct output (more on that below). Looking at the screen shot of your Excel table (despite the terrible data source as Excel is at times), you seem to have two Text columns in 'Meter Serial Number' and 'Meter Type'. I assume that the Table is named Table1_2.

    The error seems to be that the filter is expecting a Text value, so either 'Meter Serial Number' is not Text (but it is) there is something wrong with the drop-down. So my question is what are the Items of Dropdown1 and are any of the assumptions above incorrect?

    Also @powercorner , Result is the output of a Distinct filter - you might have a read of this blog of mine.

  • JerryH Profile Picture
    431 on at
    • HI Warren, 
      I can change the Datasource to Sharepoint, would that be better?errors.jpeg
    • Meter Serial Number' and 'Meter Type are both TEXT columns
    • Table is named Table1_2
    • Dropdown1 is the different serial numbers associated with that particular site.
    • Attached is also a screen snip of errors when loading the APP.

     

    I may need to start from scratch and use SP as a Datasource?

     

    Cheers

    Jerry

  • Verified answer
    WarrenBelz Profile Picture
    153,117 Most Valuable Professional on at

    Hi @JerryH ,

    It would have been good to post that error initially - it is a Data Connection issue of some sort and yes, SharePoint makes all this go away (most of it anyway) - I have a blog that may interest you.

     

    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.

  • Verified answer
    JerryH Profile Picture
    431 on at

    Thanks Warren, moving to Sharepoint worked. No issues.

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 765 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 343 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 272

Last 30 days Overall leaderboard