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.
Good Morning..
I've written a a quick DAX statement to give me the results i need on line by line basis
What i would now like to do is either sum or count the 1 in that column to give me the total of 2.. However, either i'm having a really bad day or this is more difficult than i 1st thought..
Any help would be appreciated.
Solved! Go to Solution.
@ddent1406 the general answer is to wrap your measuere with SUMX.
The important thing is what to put in the first statement and that is depandant on your model and desired visual.
For a specific visual you need to put all the columns that play affect in the matrix rows, and if they come from different tables you need to use for example summarize like what I wrote.
Hard to say without seeing your model and which are the relevant columns in your matrix / table visual but I wrote here the general code for that and see if you can easily adjust to your column names:
C_TerminalsNotTagging =
SUMX(
SUMMARIZE (
FACT_AML_SSBT_DAILY_SESSIONS_DATA,
Dim1[Column 1],
Dim2[Column 2],
... ,
... ,
... ,
FACT_AML_SSBT_DAILY_SESSIONS_DATA[Column3]
),
If(AND(CALCULATE(FACT_AML_SSBT_DAILY_SESSIONS_DATA[NickNameCount])<1,Count(__DIM_Terminals[Dim_Terminal_Key]) >0),1,0)
)
@ddent1406 the general answer is to wrap your measuere with SUMX.
The important thing is what to put in the first statement and that is depandant on your model and desired visual.
For a specific visual you need to put all the columns that play affect in the matrix rows, and if they come from different tables you need to use for example summarize like what I wrote.
Hard to say without seeing your model and which are the relevant columns in your matrix / table visual but I wrote here the general code for that and see if you can easily adjust to your column names:
C_TerminalsNotTagging =
SUMX(
SUMMARIZE (
FACT_AML_SSBT_DAILY_SESSIONS_DATA,
Dim1[Column 1],
Dim2[Column 2],
... ,
... ,
... ,
FACT_AML_SSBT_DAILY_SESSIONS_DATA[Column3]
),
If(AND(CALCULATE(FACT_AML_SSBT_DAILY_SESSIONS_DATA[NickNameCount])<1,Count(__DIM_Terminals[Dim_Terminal_Key]) >0),1,0)
)
Hi SpartaBI ,
worked great , had to chnage the if statement around a bit.. but got the result i wanted.
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 | |
11 | |
10 | |
9 | |
8 |
User | Count |
---|---|
17 | |
12 | |
11 | |
11 | |
11 |