Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
ramkula123
Helper I
Helper I

DAX query in direct mode

Hi All,

 

The below query doesnt work in direct query mode  for Calculate and All except:

Column = Table[ColD] - Calculate(MIN(Table[ColD]), ALLEXCEPT(Table, Table[ColA],Table[ColB],Table[ColC))+1
 
Can anyone help with alternatives ?
 
Thank you
2 ACCEPTED SOLUTIONS
v-diye-msft
Community Support
Community Support

Hi @ramkula123 

 

Calculate is not work in a calculated column in direct query. please change it to measure using below formula:

Measure = var a = CALCULATE(MIN(Table[ColD]),ALLEXCEPT(Table,Table[ColA],Table[ColB],Table[ColC]))
Return
MAX(Table[ColD])-a+1

 

Community Support Team _ Dina Ye
If this post helps, then please consider Accept it as the solution to help the other members find it more
quickly.

View solution in original post

Hi @ramkula123 

 

I tried all methods as far as my knowledge, but still yet to access this because of the limitations on DAX and M code under DQ mode. I think you may change it to import mode for more performance.

 

Community Support Team _ Dina Ye
If this post helps, then please consider Accept it as the solution to help the other members find it more
quickly.

View solution in original post

3 REPLIES 3
v-diye-msft
Community Support
Community Support

Hi @ramkula123 

 

Calculate is not work in a calculated column in direct query. please change it to measure using below formula:

Measure = var a = CALCULATE(MIN(Table[ColD]),ALLEXCEPT(Table,Table[ColA],Table[ColB],Table[ColC]))
Return
MAX(Table[ColD])-a+1

 

Community Support Team _ Dina Ye
If this post helps, then please consider Accept it as the solution to help the other members find it more
quickly.

Hi @v-diye-msft ,

 

Thank you for reply. This caculation needs to be as axis in one of the visuals , but since its a measure I am not able to do so .

Is there any possible workaround for this ?

 

Regards 


@v-diye-msft wrote:

Hi @ramkula123 

 

Calculate is not work in a calculated column in direct query. please change it to measure using below formula:

Measure = var a = CALCULATE(MIN(Table[ColD]),ALLEXCEPT(Table,Table[ColA],Table[ColB],Table[ColC]))
Return
MAX(Table[ColD])-a+1

 


 

Hi @ramkula123 

 

I tried all methods as far as my knowledge, but still yet to access this because of the limitations on DAX and M code under DQ mode. I think you may change it to import mode for more performance.

 

Community Support Team _ Dina Ye
If this post helps, then please consider Accept it as the solution to help the other members find it more
quickly.

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

Find out what's new and trending in the Fabric Community.