Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hello
I have a transaction table and a calendar table. The transaction table has a Datetime column, not a date column.... so I am creating a column in the transaction table called "Date" and it will contain strictly the date (no time).
In terms of model efficiency/data storage/best practice, should I create this column using PowerQuery or DAX?
Open-ended question: When is it better to create columns using Power Query? When is it better to create columns using DAX?
Solved! Go to Solution.
It's almost always better to create it in Power Query. You can read more about it here: https://www.sqlbi.com/articles/comparing-dax-calculated-columns-with-power-query-computed-columns/
@nmasimore , I agree with @Syk . If you can create it in Power Query (or even better at the data warehouse) then do so. I find that DAX is handy for creating calculated columns that require referencing multiple tables, but that shouldn't be a common requirement.
Copying DAX from this post? Click here for a hack to quickly replace it with your own table names
Has this post solved your problem? Please Accept as Solution so that others can find it quickly and to let the community know your problem has been solved.
If you found this post helpful, please give Kudos C
I work as a Microsoft trainer and consultant, specialising in Power BI and Power Query.
www.excelwithallison.com
It's almost always better to create it in Power Query. You can read more about it here: https://www.sqlbi.com/articles/comparing-dax-calculated-columns-with-power-query-computed-columns/
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
110 | |
94 | |
81 | |
66 | |
58 |
User | Count |
---|---|
150 | |
119 | |
104 | |
87 | |
67 |