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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
antlufc
Frequent Visitor

Column Refers to column in same table

Hi All,

 

I have attached a Power Bi data tabel with the fileds i have to try and get to the expected result as per below. 

I would like a DAX column that finds the Transaction type that refers to the SubscriptionVersion 1 based upon the customer reference.  I would like this result to be in ever row in the new column expected result below:

antlufc_0-1664351318212.png

 

https://1drv.ms/u/s!AivZWzcfJJzngR4sM0fFXflWaQAx?e=IIoRQk 

1 ACCEPTED SOLUTION
tamerj1
Super User
Super User

HI @antlufc 
Please refer to attached sample file with the solution

1.png

Required Result = 
VAR CurrentCustomerTable = 
    CALCULATETABLE ( First_Transaction_Type, ALLEXCEPT ( First_Transaction_Type, First_Transaction_Type[Customer Reference] ) )
VAR FirstVersion = MINX ( CurrentCustomerTable, First_Transaction_Type[SubscriptionVersion Number] )
RETURN
    MAXX (
        FILTER ( CurrentCustomerTable, First_Transaction_Type[SubscriptionVersion Number] = FirstVersion ),
        First_Transaction_Type[Transaction type]
    )

View solution in original post

2 REPLIES 2
tamerj1
Super User
Super User

HI @antlufc 
Please refer to attached sample file with the solution

1.png

Required Result = 
VAR CurrentCustomerTable = 
    CALCULATETABLE ( First_Transaction_Type, ALLEXCEPT ( First_Transaction_Type, First_Transaction_Type[Customer Reference] ) )
VAR FirstVersion = MINX ( CurrentCustomerTable, First_Transaction_Type[SubscriptionVersion Number] )
RETURN
    MAXX (
        FILTER ( CurrentCustomerTable, First_Transaction_Type[SubscriptionVersion Number] = FirstVersion ),
        First_Transaction_Type[Transaction type]
    )

Superb, worked perfectly. 

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.