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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
PBl
Regular Visitor

Problem with date & data linking

Hello everyone!

 

I'm trying to build a model where I present different kinds of data over time, and I would like to be able to put all kinds of data on the same timeline. First of all, I want to create a stacked column + line graph like below.

PBl_0-1600238838825.png

 

Now, I have multiple rows for capacity, which all have different initial capacities. In addition, I have dates when improvements are made (then the capacity is 0 for a while) and then greater than initial capacities.
The need for capacity (line in the graph) comes from a different table.
I tried creating a "master date table", and with a following measure i got it to work - given that i set the source of the capacity (n001, n002,..) as a legend.

PBl_1-1600238897315.png

 

if(FIRSTDATE(Capacities[Improvement start date])>FIRSTDATE('Date'[date]),sum(Capacities[Initial capacity]),if(FIRSTDATE(Capacities[Improvement end date])>FIRSTDATE('Date'[date]),0,sum(Capacities[New capacity])))

 

Of cource, it doesn't work without the legend, because it always checks the first date. However, in the future, I would like to present the type of capacity, not the source of it, so I'll need it fixed. Any ideas how to do it?

 

Thanks!

1 REPLY 1
Anonymous
Not applicable

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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

Top Solution Authors