Forum Discussion
DAX Formula
My first question was answered promptly by Charlotte, v-zhanti, but perhaps I should be approaching the problem in a diffferent way:
‘Dimaddon’ Table with 2 columns: Fiscal Year, Cost and single row per year
Relationship with main table, ‘Fixed’ based on Fiscal Year
Filter on Fiscal Year
Then what is DAX code to calculate: Fixed[Basis] + Dimaddon[Cost]
3 Replies
- amitchandakSuper User
PaulSB ,
one way is
sumx(Fixed , Fixed[Basis] +related( Dimaddon[Cost]) )
or
sum( Fixed[Basis] )+ Sum(Dimaddon[Cost])
- PaulSBRegular Visitor
Thanks,
I tried both and variations thereof, but none worked. I have never managed to fetch the [Cost] from the Dimaddon table.
- PaulSBRegular Visitor
Further details of my issue:
The ‘Dimcal’ table includes a [Fiscal Year] column
The ‘Dimaddon’ table has two columns: [Fiscal Year] and [Cost], with one Cost value per Fiscal Year
The ‘Fixed’ table includes a [Basis] measure
The ‘Details’ Table includes a [Date] column
Relationships:
‘Dimcal’[Fiscal Year] to ‘Dimaddon’[Fiscal Year], Many to One, Single
‘Details’[Date] to ‘Dimcal’[FullDateAlternateKey], Many to One, Single
‘Details’[Detailsid] to ‘Fixed’[Detailsid], One to One, Both
Objective:
Using a single select filter in a Visual to select a Fiscal Year,
Add a ‘Fixed’[Basis] to ‘Dimaddon’[Cost]
Such that the output from that sum changes with the [Fiscal Year] filter selection