Forum Discussion

ElevonTeam's avatar
ElevonTeam
New Member
8 years ago
Solved

Filter in calculated column in direct query mode

I have a calculated column which filter data on the basis of other column. the calculation is working fine in import mode of source but failing in direct query mode.   Can anyone please suggest a w...
  • Anonymous's avatar
    Anonymous
    8 years ago

    Hi ElevonTeam,

     

    >> the calculation is working fine in import mode of source but failing in direct query mode.

    Current there are a few limitations to use calculation in directquery mode, so you can't use calculated column to achieve your requirement.

     

    Reference link:

    Using DirectQuery in Power BI

     

    • Limitations in calculated columns: Calculated columns are limited to being intra-row, as in, they can only refer to values of other columns of the same table, without the use of any aggregate functions. Additionally, the DAX scalar functions (such as LEFT()) that are allowed will be limited to those which can simply be pushed to the underlying source, hence will vary depending upon the exact capabilities of the source. Functions that are not supported will not be listed in autocomplete when authoring the DAX for a calculated column, and would result in an error if used.

     

    >>Can anyone please suggest a workaround?

    In my opinion, I'd like to suggest you use measure to instead.

     

    Regards,

    Xiaxoin Sheng