cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
OlavRab
Regular Visitor

PowerBI Goals Dataset: Target only gets saved on single date.

Hi, I am using PowerBI Goals and connected to its dataset.

I need some help with the way the data is stored.

I am trying to create a linear graph with history of the values that were inserted. Next to that, I want a straight line as a target-line.

 

The table with data looks as follows:

OlavRab_0-1622558310355.png

If I create a line-chart from this table called 'values', I get the following.

OlavRab_1-1622558409453.png

This is because the 'target' field is filled on 27/5 and 28/5. But not on other dates.

Does anybody have a solution to take the latest filled value in the 'target' column for every name (as there are multiple names other than 'offshored hours' and insert it to all target fields. 

As I am using a direct-query connection, I cannot use the query editor.

 

Thanks already!

 

1 ACCEPTED SOLUTION

Hi, @OlavRab 

Thank you for your feedback.

please check the link down below.

 

https://www.dropbox.com/s/zdze7ukxnqrpjs6/all_targets.pbix?dl=0 

 

Picture1.png

 

 

Hi, My name is Jihwan Kim.

 

If this post helps, then please consider accept it as the solution to help other members find it faster, and give a big thumbs up.

 

Linkedin: linkedin.com/in/jihwankim1975/

Twitter: twitter.com/Jihwan_JHKIM


If this post helps, then please consider accept it as the solution to help other members find it faster, and give a big thumbs up.

Best regards, JiHwan Kim

Linkedin: https://www.linkedin.com/in/jihwankim1975/

Twitter: https://twitter.com/Jihwan_JHKIM

View solution in original post

3 REPLIES 3
Jihwan_Kim
Super User
Super User

Hi, @OlavRab 

I am not sure if I understood your question correctly but please check the below picture and the sample pbix file's link down below.

 

Target Latest value =
CALCULATE (
LASTNONBLANKVALUE ( 'Table'[Timestamp], SUM ( 'Table'[Target] ) ),
ALLEXCEPT ( 'Table', 'Table'[Name] )
)
 
 

Hi, My name is Jihwan Kim.


If this post helps, then please consider accept it as the solution to help other members find it faster, and give a big thumbs up.


Linkedin: linkedin.com/in/jihwankim1975/

Twitter: twitter.com/Jihwan_JHKIM


If this post helps, then please consider accept it as the solution to help other members find it faster, and give a big thumbs up.

Best regards, JiHwan Kim

Linkedin: https://www.linkedin.com/in/jihwankim1975/

Twitter: https://twitter.com/Jihwan_JHKIM

Hello @Jihwan_Kim 

 

Thanks so much for sharing, I think your solution is really close.

Unfortunately I forgot to mention that the 'values' table has a relationship with another table 'goals'. Therefore, your current solution does not work yet.

I have my datamodel with the exact data in the following file:

 

https://1drv.ms/u/s!AsD4rpmHpwK5hJJHfJosIjOavRT57w?e=bCoNbV

 

Hope you can see what the datamodel is and find the right solution.

 

Thanks already!

 

Olav

 

Hi, @OlavRab 

Thank you for your feedback.

please check the link down below.

 

https://www.dropbox.com/s/zdze7ukxnqrpjs6/all_targets.pbix?dl=0 

 

Picture1.png

 

 

Hi, My name is Jihwan Kim.

 

If this post helps, then please consider accept it as the solution to help other members find it faster, and give a big thumbs up.

 

Linkedin: linkedin.com/in/jihwankim1975/

Twitter: twitter.com/Jihwan_JHKIM


If this post helps, then please consider accept it as the solution to help other members find it faster, and give a big thumbs up.

Best regards, JiHwan Kim

Linkedin: https://www.linkedin.com/in/jihwankim1975/

Twitter: https://twitter.com/Jihwan_JHKIM

View solution in original post

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Power BI October Update 2021.jpg

Power BI Release

Click here to read more about the October 2021 Release!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

Teds Dev Camp Oct. 2021 768x460.jpg

Power BI Dev Camp - October 28th, 2021

Mark your calendars and join us for our next Power BI Dev Camp!