Forum Discussion

Hacharoui_101's avatar
Hacharoui_101
New Member
3 years ago
Solved

Combining two data with same calendar year into a line chart

Hello guys i am new to power BI. I am trying to get a two line area chart. The data is for predicted and current usage of electricy for the year 2023, i am trying to show both, the predicted and actual usage in same chart for each month. 

 

When i combine the electricity data to the y axis and use one of the month columns for the x axis, one of the lines shows the monthly usage and the other line is flat and shows me a summation. How do i get around this.

 

I also figured out, that when i use different calender data with diffrent data even though the year is the same. The lines doesnt show the monthly figues just a flat line with the sum.

 

I have attached a picture. I want the right graph to display the same on the left graph

 

 

 

 

  • Hacharoui_101 however if you can create a table just use the measure

    Sum of Whats from otehr table = CALCULATE(
    SUM('your other table'[Whatt]) , 'your other table'[Date] = MAX('your table you are using the axis '[Date])
    )

3 Replies

  • eliasayyy's avatar
    eliasayyy
    Icon for Memorable Member rankMemorable Member

    hello try creating a calendar table with unqiue dates , then create a one to many relationship between the calenadat table and all your otehr tables by the date column then in the x-axis put the desire column from the calendar table

    • eliasayyy's avatar
      eliasayyy
      Icon for Memorable Member rankMemorable Member

      Hacharoui_101 however if you can create a table just use the measure

      Sum of Whats from otehr table = CALCULATE(
      SUM('your other table'[Whatt]) , 'your other table'[Date] = MAX('your table you are using the axis '[Date])
      )