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

Be one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now

Reply
ncbshiva
Advocate V
Advocate V

From Tableau Fixed function to Power BI DaX

Hi ,

 

I am trying to move my reports from Tableau to Power BI and i have some below LOD function which should be written in DAX.

Can any one please help to convert Tableau LOD to Power BI DAX ?

 

{FIXED
[Dstr Name],[Product description],YEAR([Day Date]), MONTH([Day Date])
:
COUNTD(
IF
[Fulls (Crates or Hl)]>0
THEN
[Product description]
END
)

}

1 ACCEPTED SOLUTION

How about this:

-> Add 2 new column to the table:

Year = YEAR('Table'[day_date])
Month = MONTH('Table'[day_date])

-> Create a measure as below:

Measure =
CALCULATE (
    DISTINCTCOUNT ( 'Table'[Product Description] ),
    'Table'[Full(Crates & HL)] > 0,
    ALL ( 'Table'[day_date] ),
    SUMMARIZE (
        'Table',
        'Table'[Dstr Name],
        'Table'[Product description],
        'Table'[Year],
        'Table'[Month]
    )
)

View solution in original post

6 REPLIES 6
ncbshiva
Advocate V
Advocate V

Hello,

 

Can anyone help me to convert from Tableau LOD to DAX .

 

FIXED
[Dstr Name],[Product description],YEAR([Day Date]), MONTH([Day Date])
:
COUNTD(
IF
[Fulls (Crates or Hl)]>0
THEN
[Product description]
END
)

How about this:

-> Add 2 new column to the table:

Year = YEAR('Table'[day_date])
Month = MONTH('Table'[day_date])

-> Create a measure as below:

Measure =
CALCULATE (
    DISTINCTCOUNT ( 'Table'[Product Description] ),
    'Table'[Full(Crates & HL)] > 0,
    ALL ( 'Table'[day_date] ),
    SUMMARIZE (
        'Table',
        'Table'[Dstr Name],
        'Table'[Product description],
        'Table'[Year],
        'Table'[Month]
    )
)
v-frfei-msft
Community Support
Community Support

Hi @ncbshiva,

 

Kindly share your sample data and excepted result to me.

 

Regards,

Frank

Community Support Team _ Frank
If this post helps, then please consider Accept it as the solution to help the others find it more quickly.

Dstr NameProduct Descriptionday_dateFull(Crates & HL)
ACola14-9-201728989
APepsi21-8-2018765
BFanta1-4-2018631
Amstel5-12-20177633

 

 

Hi This is just the sample data , 

Hi @ncbshiva,

 

To use this measure.

 

Measure = CALCULATE(DISTINCTCOUNT(Table1[Product Description]),FILTER(Table1,Table1[Full(Crates & HL)]>0))

Capture.PNG

For more details, please check the pbix as attacched.

 

Regards,

Frank

Community Support Team _ Frank
If this post helps, then please consider Accept it as the solution to help the others find it more quickly.

Hi Frank ,

 

Thanks for ur reply, i got the distinct count number . But they have used FIXED LOD calcualtions in Tableau.

How can i use the same in Power BI DAX ?

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

Dec Fabric Community Survey

We want your feedback!

Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.

ArunFabCon

Microsoft Fabric Community Conference 2025

Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.