Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
Hi,
I am new to Power BI report building and I'm hoping you can help - I'm sure there is a simple solution but I don't know what it is!
I have a table like the one below and want to create an additional column called "ORIGINAL SOURCE" that shows the value in the SOURCE column for EVENT NO 1 in every row for the relevant REF VALUE.
| REF | EVENT_NO | SOURCE |
| 001 | 1 | A |
| 001 | 2 | A |
| 001 | 3 | B |
| 001 | 4 | B |
| 001 | 5 | D |
| 002 | 1 | C |
| 002 | 2 | D |
| 002 | 3 | A |
| 002 | 4 | B |
| 002 | 5 | C |
| 002 | 6 | D |
So it will look like this:
| REF | EVENT_NO | SOURCE | ORIGINAL SOURCE |
| 001 | 1 | A | A |
| 001 | 2 | A | A |
| 001 | 3 | B | A |
| 001 | 4 | B | A |
| 001 | 5 | D | A |
| 002 | 1 | C | C |
| 002 | 2 | D | C |
| 002 | 3 | A | C |
| 002 | 4 | B | C |
| 002 | 5 | C | C |
| 002 | 6 | D | C |
I would appreciate anyone's advice on the best way to achieve this.
Many Thanks,
Solved! Go to Solution.
@Green_G you can write a measure like this
Measure2 =
//what is the min event # by REF
VAR one =
CALCULATE (
MIN ( 'Table 1'[EVENT_NO] ),
ALL ( 'Table 1' ),
VALUES ( 'Table 1'[REF] )
) // what is the source when event = one by ref
VAR two =
CALCULATE (
MIN ( 'Table 1'[SOURCE] ),
FILTER (
ALL ( 'Table 1' ),
'Table 1'[EVENT_NO] = one
&& 'Table 1'[REF] = MAX ( 'Table 1'[REF] )
)
)
RETURN
two
@Green_G you can write a measure like this
Measure2 =
//what is the min event # by REF
VAR one =
CALCULATE (
MIN ( 'Table 1'[EVENT_NO] ),
ALL ( 'Table 1' ),
VALUES ( 'Table 1'[REF] )
) // what is the source when event = one by ref
VAR two =
CALCULATE (
MIN ( 'Table 1'[SOURCE] ),
FILTER (
ALL ( 'Table 1' ),
'Table 1'[EVENT_NO] = one
&& 'Table 1'[REF] = MAX ( 'Table 1'[REF] )
)
)
RETURN
two
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
Check out the November 2025 Power BI update to learn about new features.
| User | Count |
|---|---|
| 20 | |
| 11 | |
| 10 | |
| 4 | |
| 4 |
| User | Count |
|---|---|
| 34 | |
| 31 | |
| 19 | |
| 12 | |
| 11 |