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
Anonymous
Not applicable

Return earliest value of a boolean/text value based on snapshot dates

Hi guys,

 

I've been banging my head against this challenge for a little over a week now, so I was hoping some of you smart people can help out! I have seen solutions relating to numerical values for snapshot comparisons that seem to work, but I can't figure out how to convert that when it's a boolean/string. 

 

So I've got a Snowflake schema in my data model view in Power BI. My company is also using daily snapshots of the data so we can follow the progress over time. This especially relates to our forecasts. We have a boolean field that denotes whether we expect to order to come through or not. When we sum up the expected orders with a snapshot date at the beginning of the month, this number will change throughout the month because orders are moved in and out of the expected field. To easily surface and investigate what those moved orders are, I would like to give the user a comparison period slicer to chose and show them the expected deals along with deals that were changed. In terms of the slicer (having a relative date slicer or two separate slicers) I'm open to suggestions. 

I've tried creating calculated columns showing the expected value at the first snapshot date (having a relative date slicer on snapshot date or two different slicers - one for a inactive relationship snapshot date dim and one for an active), but with no success because I can't get it to return the expected field in a CALCULATE function based on my conditions (USERELATIONSHIP to an inactive snapshot date dim, ALL(snapshot date dim) from primary relationship. 

 

I would really appreciate any help! 

 

Edit: I've added the data model and an example of the data and desired outputScreenshot 2021-03-07 at 10.10.38.png

 

This is my essentially the desired output based on a snapshot date filter between 1-4. Expected start would show what the expected value is at the start period selected regardless of what snapshot date we are looking at now. 

Snapshot DateRecordExpectedExpected Start
01-01-2020aaaaTRUETRUE
02-01-2020aaaaTRUETRUE
03-01-2020aaaaFALSETRUE
04-01-2020aaaaFALSETRUE
01-01-2020bbbbFALSEFALSE
02-01-2020bbbbTRUEFALSE
03-01-2020bbbbTRUEFALSE
04-01-2020bbbbTRUEFALSE

Hopefully that's enough to go by otherwise I'm happy to add more! 

2 REPLIES 2
rfigtree
Resolver III
Resolver III

i dont think anyone will give you a solution without some sort of example data/model.

Anonymous
Not applicable

Thanks - first post I've made on here. I've added more info that hopefully provides better context. 

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