Forum Discussion

ChazTime's avatar
ChazTime
Frequent Visitor
1 year ago
Solved

Direct Query Filtering Values in Visual based on another Columns Values

Hello, Using PBI Direct Query data, I have a table where I need to show specific (or group of specifc values) based on another columns values. Using a table visual, I want to only show the data th...
  • v-pnaroju-msft's avatar
    1 year ago

    Hi ChazTime,

    Thank you for your detailed follow-up and your efforts in debugging the scenario.

    While the ShowVIS logic functions correctly in a straightforward setup, the inclusion of additional filters such as Loc ID in a DirectQuery model may cause the measure to malfunction. This is due to the manner in which DAX is evaluated and translated into SQL. When complex filters are applied or measures rely on CALCULATE logic involving related tables, Power BI’s query folding can behave unpredictably in DirectQuery mode. This may result in incorrect or uniform outputs, for example, all values being 1.

    Kindly consider the following workaround options which might assist in resolving the issue:

    1. Use a SQL view to pre-aggregate or filter the data at the source.
    2. Employ a composite model (Import + DirectQuery) for enhanced flexibility in DAX.

    If you find our response helpful, please mark it as the accepted solution and provide kudos. This will help other community members encountering similar queries.

    Should you have any further questions, please feel free to reach out to the Microsoft Fabric community.

    Thank you.