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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
Samba777
Frequent Visitor

Need Help Previous status shows color and current status shows to some other color in Matrix Visual

Hi All,

 

Usually when Title shows current status of values shows Green Color and other previous color shows yellow color( which i added expected result)

 

I am looking for suggesions( Conditional formatting ) how can we add bar colors present status and prevous status of each title.

Suppose 1st item is Closed (Green color), Previous 3 statuses Active ,Dev Complete and IN Test (Yellow Color).

 

Samba777_1-1668524035730.png

 

 

2 ACCEPTED SOLUTIONS
v-yanjiang-msft
Community Support
Community Support

Hi @Samba777 ,

According to your description, I create a sample:

vkalyjmsft_0-1668592637408.png

Here's my solution.

1.Create a table to define the order of Status, the two tables are related with Status column.

vkalyjmsft_1-1668592709961.png

2.Create a calculated column in fact table:

Column = RELATED('Status'[Rank])

3.Create a measure.

Color =
IF (
    MAX ( 'Table'[Value] ) = 1,
    "Green",
    IF (
        MAX ( 'Table'[Column] )
            < MAXX (
                FILTER (
                    ALL ( 'Table' ),
                    'Table'[Title] = MAX ( 'Table'[Title] )
                        && 'Table'[Value] = 1
                ),
                'Table'[Column]
            ),
        "Yellow"
    )
)

When apply conditional formating in the matrix visual, you can see the blank values can't show color.

vkalyjmsft_2-1668592883709.png

To have the color to show, we should put a value in the current context, so I create a simple blank measure. When put in it, get the correct result:

vkalyjmsft_3-1668593118611.png

I attach my sample below for your reference.

 

Best Regards,
Community Support Team _ kalyj

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Samba777
Frequent Visitor

This Works Awesome.

View solution in original post

2 REPLIES 2
Samba777
Frequent Visitor

This Works Awesome.

v-yanjiang-msft
Community Support
Community Support

Hi @Samba777 ,

According to your description, I create a sample:

vkalyjmsft_0-1668592637408.png

Here's my solution.

1.Create a table to define the order of Status, the two tables are related with Status column.

vkalyjmsft_1-1668592709961.png

2.Create a calculated column in fact table:

Column = RELATED('Status'[Rank])

3.Create a measure.

Color =
IF (
    MAX ( 'Table'[Value] ) = 1,
    "Green",
    IF (
        MAX ( 'Table'[Column] )
            < MAXX (
                FILTER (
                    ALL ( 'Table' ),
                    'Table'[Title] = MAX ( 'Table'[Title] )
                        && 'Table'[Value] = 1
                ),
                'Table'[Column]
            ),
        "Yellow"
    )
)

When apply conditional formating in the matrix visual, you can see the blank values can't show color.

vkalyjmsft_2-1668592883709.png

To have the color to show, we should put a value in the current context, so I create a simple blank measure. When put in it, get the correct result:

vkalyjmsft_3-1668593118611.png

I attach my sample below for your reference.

 

Best Regards,
Community Support Team _ kalyj

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

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