Forum Discussion
T_JF2022
4 years agoFrequent Visitor
Replace table columns without power query
I have a table that shows the sales of a fiscal year, divided into months on the basis of orders. This turnover is then subdivided again on customer groups and overall result. Now I want to replace ...
Adescrit
4 years agoImpactful Individual
You could use an IF statement I think. So if you have a Calendar / Date table that is connected to both 'Table 1' (from file 1) and 'Table 2' in your data model. In the Calendar table would be a Month column that contains either the name of the month or the month number - whatever you see fit. Then the DAX you could apply to carry out this calculation would be something like:
Total Sales =
IF (
'Calendar'[Month] = "Feb",
SUM ( 'Table 2'[Sales] ),
SUM ( 'Table 1'[Sales] )
)