cancel
Showing results for 
Search instead for 
Did you mean: 

Fabric is Generally Available. Browse Fabric Presentations. Work towards your Fabric certification with the Cloud Skills Challenge.

Reply
Kopek
Helper IV
Helper IV

Showing selected qtr and previous qtr in the matrix

Hello,

 

 

I have a matrix which shows some qtr values based on a slicer selection
(when q1 2022 is slected it shows appropriate data for Q1 2022, when Q2 2023 is selected, then shows values for Q2 2023 and so on).

What i want to achieve is to in addition to selected qtr have a column with previous qtr values.

 

The trick is, i cannot change a slicer type - it needs to be a single selection dropdown, as it is synced with other pages where it is driven from.
So i could not scratch my head round what calculation to prepare (possible a calculated table?) so that i am having a selcted qtr values + previous qtr values in the matrix visible.

 

Any ideas ?

 

Thanks in advance 🙂

 

 

1 ACCEPTED SOLUTION
mickey64
Responsive Resident
Responsive Resident

Step 0: I make and use this DATA Table.

mickey64_0-1695387274822.png

 

Step 1: I make a calendar table and add a relationship.

mickey64_0-1695386750176.png

mickey64_1-1695387353528.png

 

Step 2: I make a measure 'Total_PreQ'.

    Total_PreQ = CALCULATE(SUM(DATA[Value]),PREVIOUSQUARTER('Calendar'[Date]))

 

Step 3: I make a slicer and a matrix.

mickey64_2-1695387011121.png

mickey64_3-1695387080226.png

 

View solution in original post

4 REPLIES 4
Kopek
Helper IV
Helper IV

hi @mickey64 , i know how to create a measure to count previous qtr values, but how to embedded that in one matrix as a column ?

 

So what i want to achievie is a below matrix:
What i am currently able to have is a first two columns and dropdown slicer which is a single qtr selection driven on previous pages

 Q1 2022 (qtr determined by slicer selection)Q4 2021 ( that column and underneath values to be calcuated based on a slicer selection qtr-1)
1valuevalue
  1.1valuevalue
      1.1.1valuevalue
      1.1.2valuevalue
      1.1.3valuevalue

 

 

 

mickey64
Responsive Resident
Responsive Resident

Step 0: I make and use this DATA Table.

mickey64_0-1695387274822.png

 

Step 1: I make a calendar table and add a relationship.

mickey64_0-1695386750176.png

mickey64_1-1695387353528.png

 

Step 2: I make a measure 'Total_PreQ'.

    Total_PreQ = CALCULATE(SUM(DATA[Value]),PREVIOUSQUARTER('Calendar'[Date]))

 

Step 3: I make a slicer and a matrix.

mickey64_2-1695387011121.png

mickey64_3-1695387080226.png

 

Hi @mickey64 , you are right! i was looking at the column/ table level solution... but i can achieve that the other way round and dummy the column headers at the end.

Thanks for unfreezing my brain ! 🙂

 

mickey64
Responsive Resident
Responsive Resident

For your reference.

I make a measure.

    Previous Q = CALCULATE(SUM([Value]), PREVIOUSQUARTER('Calendar'[Date]))

Helpful resources

Announcements
PBI November 2023 Update Carousel

Power BI Monthly Update - November 2023

Check out the November 2023 Power BI update to learn about new features.

Community News

Fabric Community News unified experience

Read the latest Fabric Community announcements, including updates on Power BI, Synapse, Data Factory and Data Activator.

Power BI Fabric Summit Carousel

The largest Power BI and Fabric virtual conference

130+ sessions, 130+ speakers, Product managers, MVPs, and experts. All about Power BI and Fabric. Attend online or watch the recordings.

Top Solution Authors
Top Kudoed Authors