Skip to main content

Notifications

Finance | Project Operations, Human Resources, ...
Suggested answer

Query ranges/filter

(0) ShareShare
ReportReport
Posted on by 1,550
Hi,

I have a query with two datasources (table1 and table2) inner joined
and there is a range on the query for table2 based on status

As you can see from the picture below, the Status field range appears based on query range. And the recordId range field appears because i'm setting range from caller in the controller class.

My question is
1. why table1 is returning field1 and field2 in the filter? from where did it come from and how can i remove them?
2. can I hide recordId range from table2?

 
  • Suggested answer
    Bharani Preetham Peraka Profile Picture
    Bharani Preetham Pe... 3,587 Super User 2024 Season 1 on at
    Query ranges/filter
    If these 2 fields are there in primary key of that table, then these may appear. You can via code or directly in query, make these ranges to hidden. Same will work for record- ID too.
  • Martin Dráb Profile Picture
    Martin Dráb 230,842 Most Valuable Professional on at
    Query ranges/filter
    Unfortunately, you forgot to explain your scenario. I'll assume you're talking about about query selection in SysOperation framework (or maybe RunBase). Please confirm.
     
    The framework indeed automatically add some fields to the dialog. Unfortunately, you hid all information from the screenshot, so I can only guess, but I assume that Field1 and Field2 of Table1 are there because they form the primary key of the table. Let's talk what to do with it (if at all) after you confirm which framework you're using (or what else you're doing) and whether the fields are from PK or not.
  • André Arnaud de Calavon Profile Picture
    André Arnaud de Cal... 291,969 Super User 2025 Season 1 on at
    Query ranges/filter
    Hi Junior AX,
     
    There are options to lock or hide a range. To have the unwanted fields removed from the form, you can set the property Status for the ranges to 'hidden'. You mentioned you didn't add fields as ranges for Table1. Are these fields the primary key fields? You can add the same field to your query and also hide them with the property.

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

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Announcing Forum Attachment Improvements!

We're excited to announce that attachments for replies in forums and improved…

Vahid Ghafarpour – Community Spotlight

We are excited to recognize Vahid Ghafarpour as our February 2025 Community…

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,969 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 230,842 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Product updates

Dynamics 365 release plans