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 / How to filter "Multi t...
Power Apps
Unanswered

How to filter "Multi table" lookup field via JavaScript in MDA

(0) ShareShare
ReportReport
Posted on by 75

Hi,

I tried to use the addCustomFilter but it is not working.

ThareLyn_0-1642746332208.png


No error being thrown, but when you click on the lookup field it will says the you have a invalid XML format

ThareLyn_1-1642746425194.png


I am confident that my XML is correct. So my suspicion is that this error is being thrown because there are multiple tables inside the look-up field.

I tried to search about javascript filter to a multi-table lookup field but I can't find anything helpful on the internet.

Does anyone know how to do this? Thank you very much

I have the same question (0)
  • Guido Preite Profile Picture
    1,488 Super User 2024 Season 1 on at

    the code looks correct (I assume the rest of the code will show the closing of the presearch function).

    Personally I would try 2 things:

    1) convert the addCustomFilter row inside a separate function and call the named function inside your presearch (probably you get the same error but it's an easy test)

    2) create a normal lookup pointing just to account and change the code to point to the new lookup, if you don't get an error means that there is a bug inside the platform (you didn't specify if this multi-table lookup is a Customer or a Polymorphic one) and you can open a ticket to MS support

    also make sure your xml is in a single line, the encoding of new line can eventually mess up (you can test it together with number 1)

    hope it helps

  • Diana Birkelbach Profile Picture
    3,072 Most Valuable Professional on at

    Hi @ThareLyn , 

     

    I might be wrong, but I have the strong feeling that in your fetchXml, between operator='eq' and value='77...' there is a space (blank) missing.

     

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!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 529 Most Valuable Professional

#2
Haque Profile Picture

Haque 230

#3
Kalathiya Profile Picture

Kalathiya 217 Super User 2026 Season 1

Last 30 days Overall leaderboard