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
acodato
Regular Visitor

Comparing two sets sets of SCD-2 table based on "from date" and "to date"

Hi,

 

I have a SCD-2 table that has basically the following structure:

 

acodato_0-1626188243833.png

 

The user can select two independent snapshot dates "From (A)" and "To (B)" and the Power BI report should display the values of from (A) to (B) in a table like below:

 

acodato_1-1626188328571.png

 

The SCD-2 table has hunbreds of thousands of records and there are many other measures that need to be calculated based on the selected keys (records). I am looking for the most efficient way of doing this.

 

Thanks,

1 ACCEPTED SOLUTION
v-shex-msft
Community Support
Community Support

HI @acodato,

You can't use only one table to achieve your requirement.

In my opinion, I'd like to suggest you duplicate the row table and use one as the start and another one as the end to create the table visual to show the results. 

For the date slicer, I think you need to create an unconnected date table as the source of the slicer and use the min date on one table, the max on another table for filter operations.

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin
If this post helps, please consider accept as solution to help other members find it more quickly.

View solution in original post

3 REPLIES 3
acodato
Regular Visitor

With two tables how do I get to the single report table described above?

Hi @acodato,

After I further test with your scenario I found my suggestion can filter the match records but these results can't be merged into one row. They will keep corresponding records part, other parts will display blank.
For example:
row 1: start part, blank
row 2: blank, end part
row 3: start part, blank
row 4: blank, end part

Regards,
Xiaoxin Sheng

Community Support Team _ Xiaoxin
If this post helps, please consider accept as solution to help other members find it more quickly.
v-shex-msft
Community Support
Community Support

HI @acodato,

You can't use only one table to achieve your requirement.

In my opinion, I'd like to suggest you duplicate the row table and use one as the start and another one as the end to create the table visual to show the results. 

For the date slicer, I think you need to create an unconnected date table as the source of the slicer and use the min date on one table, the max on another table for filter operations.

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin
If this post helps, please consider accept as solution to help other members find it more quickly.

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.