Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
How to summation only which starts with NG_ and that summation should be shown in NG_GYM
Iam using matrix visual in power bi exposure column was created by using dax measure
Expos = CALCULATE(SUM('TA Expos'[expo]),USERELATIONSHIP('Calendar'[Date],'TA Expos'[Trading_Period_date]))
Note:
Remaining all other curve should show the values as it is without doing any summation
Currenlty matrix visual data looks like below:
Curve | Expos | TL | HD |
NG_AE | 5 | 5 | 5 |
NG_HSC | -10 | 5 | 5 |
NG_DTI | -20 | 4 | 24.73 |
NG_GYM | -20 | 1 | 0 |
LNG_JK | 5 | 1 | 5 |
AD OFF 216 | 5 | 3 | 5 |
BR_Nor | -250.72 | 2 | 5 |
Expected output:
Curve | Expos | TL | HD |
NG_AE | 5 | 5 | 5 |
NG_HSC | -10 | 5 | 5 |
NG_DTI | -20 | 4 | 24.73 |
NG_GYM | -45 | 1 | 0 |
LNG_JK | 5 | 1 | 5 |
AD OFF 216 | 5 | 3 | 5 |
BR_Nor | -250.72 | 2 | 5 |
Thanks,
SBC
To sum only the rows that start with "NG_" and show the result in the "NG_GYM" row, you can create a new measure in Power BI using the following DAX expression:
This measure creates a variable "SelectedRows" that filters only the rows where the "Curve" column starts with "NG_". It then uses the SUMX function to sum the "Expos" column for the selected rows.
To show the result in the "NG_GYM" row, you can add this measure to the "Values" section of the matrix visual and drag the "Curve" column to the "Rows" section. The other rows will show the original values from the "Expos" measure.
Hi @MAwwad
thanks for the reply but it showing wrong data showing blank values for the other than NG_ and for NG- related showing different data
could you please check at you end once,are we getting the expected output? as i mentioned
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
11 | |
9 | |
8 | |
6 | |
5 |
User | Count |
---|---|
19 | |
17 | |
12 | |
9 | |
9 |