Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Anonymous
Not applicable

Producing a line graph with countifs

Hello all, 

 

I'm relatively new to PowerBI, so i'm not really used to the DAX syntax yet, which is the reason i'm posting this question. 

 

Normally i make reports based on excel-made graphs. I am currently trying to reproduce a report in Powerbi. Most charts are working fine, but i have one graph i cannot seem to make. 

 

The problem:

I want to make a line graph with values based on multiple filters. An example of said line graph in excel.

test1.PNG

The graph is based on a summary made out of a set of data consisting out of three columns:

columns(values)

  1. Weekday (monday,tuesday,wednesday,thursday,friday)
  2. type(Variable A, Variable B, Variable C)
  3. Status(In use, Temporarily not in use, Not in use)

From this set of data i produced the following table:

 

                         Monday       Tuesday    Wednesday   Thursday   Friday

Variable A          45%                50%              41%            46%         38%
Variable B          36%                38%              27%            35%         20%
Variable C          13%                39%              23%            34%         %13

 

The formula i used to produce the summary above is:
used variables for example("Monday", "Variable A", "In use") 

=COUNTIFS(Data[Weekday];"Monday"
                    ;Data[Type];"Variable A"
                    ;Data[Status];"In use")

 /
  COUNTIFS(Data[Weekday]"Monday"
                    ;Data[Type];"Variable A")

 

From the summary i made the graph. I tried several things in powerbi, but i cannot seem to make it work. Can anyone explain to me how to produce the same graph in Powerbi?
Best Regards,

Pim Schoeman

 

 

1 REPLY 1
v-evelk
Microsoft Employee
Microsoft Employee

Hello Pim Schoeman,

 

DAX is out of our expertise because it is a feature of Desktop so, it is more efficient to ask all the questions regarding DAX in the Desktop thread.

 

Kind Regards,

 

Evgenii Elkin,
Software Engineer
Microsoft Power BI Custom Visuals
pbicvsupport@microsoft.com

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Kudoed Authors