The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredCompete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.
I have a table in the following format:
ID | Status |
1ABC | Quote |
2ABC | Sold |
3XYZ | Expired |
4EFG | Confirmed |
5JKL | Confirmed |
I want to calculate how may confirmed IDs there are against the total IDs. Sorry if this is simple, I'm just starting out with DAX!
Thanks in advance...
Solved! Go to Solution.
Here you are:
% Confirmed =
DIVIDE (
CALCULATE (
COUNTROWS ( VALUES ( 'Table'[ID] ) ),
KEEPFILTERS ( 'Table'[Status] = "Confirmed" )
),
COUNTROWS ( VALUES ( 'Table'[ID] ) )
)
Selected confirmed percentage of all selected ID
Formatting as percentage is done in the Measuretools ribbon. You need to click on the Measre in the fields list to see that ribbon. You need to click on Data in View ribbon to see the fields list.
Here you are:
% Confirmed =
DIVIDE (
CALCULATE (
COUNTROWS ( VALUES ( 'Table'[ID] ) ),
KEEPFILTERS ( 'Table'[Status] = "Confirmed" )
),
COUNTROWS ( VALUES ( 'Table'[ID] ) )
)
Selected confirmed percentage of all selected ID
Formatting as percentage is done in the Measuretools ribbon. You need to click on the Measre in the fields list to see that ribbon. You need to click on Data in View ribbon to see the fields list.
User | Count |
---|---|
18 | |
8 | |
7 | |
6 | |
6 |
User | Count |
---|---|
27 | |
13 | |
12 | |
9 | |
8 |