Forum Discussion

Koritala's avatar
Koritala
Post Patron
1 year ago
Solved

Conditional Column Creation

Hi,

I just want to find the best approach to the creation of a conditional column.

 

What is the best place to create a conditional column? Is it best place to create uisng conditinal column option in Query Editor (or)

using DAX expresssion creating at the front end (using New Column)? Which one is the best approach with respect to performance when we are working with large datasets.

Thanks,

Sri

  • Hi Koritala 

     

     With report performance in mind, the best place to add your calculated columns is at the data source before ingestion. In Fabric, this can be done in a notebook or dataflow gen 2.

     Within BI, power query is better for static calculations (eg column 1 + column 2). Power query also calculates once at load, reducing your model size. DAX is better for dynamic calculation that require relationships but increases the size of the model.

     

    I hope this helps, please give a thumbs up and mark as solved if it does, thanks!

5 Replies

  • Hi Koritala 

     

     With report performance in mind, the best place to add your calculated columns is at the data source before ingestion. In Fabric, this can be done in a notebook or dataflow gen 2.

     Within BI, power query is better for static calculations (eg column 1 + column 2). Power query also calculates once at load, reducing your model size. DAX is better for dynamic calculation that require relationships but increases the size of the model.

     

    I hope this helps, please give a thumbs up and mark as solved if it does, thanks!

  • Greg_Deckler's avatar
    Greg_Deckler
    Community Champion

    Koritala This is going to depend potentially. I say that because if you break query folding for your query then the query could perform much worse. So it really depends on your specific query and whether or not the addition of your column in Power Query breaks query folding.

  • v-sdhruv's avatar
    v-sdhruv
    Community Support

    Hi Koritala ,

    Just wanted to check if you got a chance to review the  explaination provided and whether that helped you gain an understanding?

    Thank You

  • v-sdhruv's avatar
    v-sdhruv
    Community Support

    Hi @Koritala ,

    Just wanted to check if you got a chance to review the  explaination provided and whether that helped you gain an understanding?

    Thank You

  • v-sdhruv's avatar
    v-sdhruv
    Community Support

    Hi Koritala ,

    Since we didnt hear back, we would be closing this thread.
    If you need any assistance, feel free to reach out by creating a new post.

    Thank you for using Microsoft Community Forum