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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
BMac-Coop
Frequent Visitor

Two lines in a chart, one showing values one showing count

I'm stuck trying to get two lines working right on a chart.

 

One dataset has:

THINGWEEKCREATED
A1
B1
C2

 

The other dataset has target goals:

WEEKNUMTARGET
12
23

In this dataset, I have Summarize By in the model set to "None"

 

I'm trying to have a line chart where it plots one line with the count of things in each week, and another line that shows the goal.  I start with an Axis of WEEKCREATED and a Value of "Count of THING".  I can't for the life of me figure out how to put in the straight value of TARGET.

 

Any help is appriciated!  Thanks!

1 ACCEPTED SOLUTION
AlB
Community Champion
Community Champion

Hi @BMac-Coop 

You can best create a date table with the week numbers. Then set up relationships between DateT and both your actuals and target tables. You can then create the line chart with DateT[Week] in the x axis and the count of "things" in values. It's advisable to create explicit measures for the counts rather than using implicit ones.

See it all at work in the attached file.

Please mark the question solved when done and consider giving a thumbs up if posts are helpful.

Contact me privately for support with any larger-scale BI needs, tutoring, etc.

Cheers 

SU18_powerbi_badge

View solution in original post

3 REPLIES 3
AlB
Community Champion
Community Champion

Hi @BMac-Coop 

You can best create a date table with the week numbers. Then set up relationships between DateT and both your actuals and target tables. You can then create the line chart with DateT[Week] in the x axis and the count of "things" in values. It's advisable to create explicit measures for the counts rather than using implicit ones.

See it all at work in the attached file.

Please mark the question solved when done and consider giving a thumbs up if posts are helpful.

Contact me privately for support with any larger-scale BI needs, tutoring, etc.

Cheers 

SU18_powerbi_badge

BMac-Coop
Frequent Visitor

It's not loading as I'd expect in the file you provided.  The line for TARGET is straight at a value of 1.  The goal is the TARGET number changes week over week.  It's showing the number of TARGET rows for the week I think, not the value of the TARGET row.

I think I figured it out.  I had to change the TARGET value datapoint from "Count of TARGET" to Sum of TARGET (which just displays now as "TARGET").  With that change it looks as I'd expect.  Thanks!  Off to the next thing to figure out!

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

Find out what's new and trending in the Fabric community.

July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.

Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.