cancel
Showing results for
Did you mean:

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Helper III

## Selecting dimension to show in matrix

Hi All, I hope you are doing well. I want to know if it is possible to have show selected dimension even if wihout value.

 Brand Flavor/Size XXX 1L XXX 2L XXX 3L YYY 1L YYY 3L YYY 5L ZZZ Apple ZZZ Organe ZZZ Watermelon

In the above figure we can see that Brand XXX has 1L, 2L, 3L and Brand YYY has 1L, 3L and 5L. Similary, brand ZZZ has Apple, Orange, Watermelon.  Considering our data, we will have Size/Flavor dimension with attributes 1L, 2L, 3L, 5L, Apple, Orange, Watermelon.  But when I put in a matrix view I want this kind of table.

The table should show all the 1L, 2L, 3L, 5L dimension for Brand XXX and Brand YYY but not for Brand ZZZ. Whereas Brand ZZZ should only  has its flavor and size and not other.Please guide

1 ACCEPTED SOLUTION
Community Support

Below is my table:

The following DAX might work for you:

``````CustomDimensionTable =
UNION(
SELECTCOLUMNS(
FILTER('Table', 'Table'[Brand] = "XXX" || 'Table'[Brand] = "YYY"),
"Brand", 'Table'[Brand],
"Dimension", 'Table'[Flavor]
),
SELECTCOLUMNS(
FILTER('Table', 'Table'[Brand] = "ZZZ"),
"Brand", 'Table'[Brand],
"Dimension", 'Table'[Flavor]
)
)``````

The final output is shown in the following figure:

Best Regards,

Xianda Tang

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

2 REPLIES 2
Community Support

Below is my table:

The following DAX might work for you:

``````CustomDimensionTable =
UNION(
SELECTCOLUMNS(
FILTER('Table', 'Table'[Brand] = "XXX" || 'Table'[Brand] = "YYY"),
"Brand", 'Table'[Brand],
"Dimension", 'Table'[Flavor]
),
SELECTCOLUMNS(
FILTER('Table', 'Table'[Brand] = "ZZZ"),
"Brand", 'Table'[Brand],
"Dimension", 'Table'[Flavor]
)
)``````

The final output is shown in the following figure:

Best Regards,

Xianda Tang

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

Super User

Hi @Mkrishna
If I understood you correctly try to use the option "show items with no data".

please show a desired result according to the tables that you used at a question or link to small pbix to work with

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