Don't miss your chance to take the Fabric Data Engineer (DP-600) exam for FREE! Find out how by attending the DP-600 session on April 23rd (pacific time), live or on-demand.
Learn moreNext up in the FabCon + SQLCon recap series: The roadmap for Microsoft SQL and Maximizing Developer experiences in Fabric. All sessions are available on-demand after the live show. Register now
Hi,
I want to count the number of times a field has a number entered, from January to Dec. In excel, I would just use a count formula and reference the columns, what should I use within PBI?
Thanks
Solved! Go to Solution.
Hi @timward10 ,
Firstly make sure the data type of your columns is whole number.
Then you can create a Table visualization and add columns you need with Count Function.
Power BI will show blank if there is no data.
If you want to show 0 instead of blank, you need to create 12 measures due to your data model.
The measures are similar, they look like as below.
Count Number Jan 25 = CALCULATE(COUNT('Table'[Total Rev Jan 25]))+0
...
Result is as below.
Best Regards,
Rico Zhou
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
@timward10 , Use this
CountNumbers = COUNTROWS(
FILTER(
YourTable,
ISNUMBER(YourTable[YourField]) &&
YourTable[DateColumn] >= DATE(Year, 1, 1) &&
YourTable[DateColumn] <= DATE(Year, 12, 31)
)
)
Proud to be a Super User! |
|

Table is attached, I would expect to see all of them columns return zero, apart from the ones that have numbers in, they would return one and so on.
What fields are you referencing in your formula?
Thanks
Hi @timward10 ,
Firstly make sure the data type of your columns is whole number.
Then you can create a Table visualization and add columns you need with Count Function.
Power BI will show blank if there is no data.
If you want to show 0 instead of blank, you need to create 12 measures due to your data model.
The measures are similar, they look like as below.
Count Number Jan 25 = CALCULATE(COUNT('Table'[Total Rev Jan 25]))+0
...
Result is as below.
Best Regards,
Rico Zhou
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Perfect @Anonymous! It was just the formula I was looking for, if I add the columns together this works how I need it to! Thank you!
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.
Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
| User | Count |
|---|---|
| 48 | |
| 43 | |
| 39 | |
| 19 | |
| 17 |
| User | Count |
|---|---|
| 69 | |
| 63 | |
| 32 | |
| 30 | |
| 23 |