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
DM_BI
Helper III
Helper III

Concatenate labels in matrix

Hello,

 

Is it possible to concatenate labels in the columns of a matrix ?

 

I have in columns the day of month and I want to show the month also because my month goes to july 1st to august 5.

Captura.PNG

 

In this exemple the header represents the day of month and the first row reprensents the sales. The problem is that 1st of july and 1st of august are in the same column (it's been summed)...  What I want is the header like that : 1 2 3 ...30 31 1 2 3 5. So the idea would be to add a line above with name of month (that's why I talk about concatenate labels) but if there is another solution I am open.

 

Thank you very much for your help.

 

DM

1 ACCEPTED SOLUTION

Hi @DM_BI ,

Do you want to get the output below?

Capture.PNG

If it is your case, you could create with date hierarchy (Month-Day )in matrix.

If you still need help, please share your data sample so that we could help further on it.

Best Regards,

Cherry

 

Community Support Team _ Cherry Gao
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

8 REPLIES 8
Anonymous
Not applicable

@DM_BI 

 

1) If you have date column in your data then you can format your date column "MMMM d" and use tin column header. If you do not have date column then create one using dax from month and day.

2) If you want format like "01-08" then create calculated column either in DAX or Power query and use that column in column header of matrix.

 

Date2 = FORMAT('Table'[Date],"dd-mm")

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

 

@Anonymous Thank you for your help. I thought about it but unfortunately my end user wants to see only the day of the month and not DD-MM or MMMM-D because it was in that format in excel and because if I put the month we cannot see everything in the table...

Hi @DM_BI ,

Do you want to get the output below?

Capture.PNG

If it is your case, you could create with date hierarchy (Month-Day )in matrix.

If you still need help, please share your data sample so that we could help further on it.

Best Regards,

Cherry

 

Community Support Team _ Cherry Gao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

@v-piga-msft hi, this is exactly what I was trying to do! It finally works thank you. Last question/problem that I have : I can only sort by what I have in my rows, but I would like to sort by month (what I have in columns). Do you know if I can do that ? Because for the moment August comes before July.

 

Thank you very much for your time.

 

DM

Hi @DM_BI ,

Sorry for the delay.

We could use the feature sort by column to achieve your desired sort.

Firstly, you need to create an Index column based on the order.

Then sort the month column by index column under data view like below.

Untitled.png

Hope this can help you.

Best  Regards,

Cherry

 

Community Support Team _ Cherry Gao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Hi Cherry,

 

Thank you for your answer. I have tried but sorting by number of month doesn't work in my DimDate table because there are several lines (not unique values). Do I really have to create another table with uniques months to be able to sort the months? I already have so many tables in my model.

 

Thank you

 

DM

You can create a column for the numbers of the month then you can use this to sort your month.

Thanks it works !!

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.