cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
jellis1971
Helper II
Helper II

Dimension Description as a Column

Hi:

I have a couple of columns in a Power BI Report, both representing ERP's dimension codes (dimension values).

I want to add the description of the dimension values, but I only want it to display the description for one of these two codes (columns). 

In the dimensions table, the "description" is the "Display Name".

How do I place an "if, then" statement in Power BI to "tell" the column to only display the description for the one code (column) that I have in mind?

Thanks!

jellis1971

1 ACCEPTED SOLUTION
selimovd
Super User
Super User

Hey @jellis1971 ,

 

I didn't fully understand how you want to add the description. Can you explain that better?

If the description exists in a column and you only want to change the visibility, the following approach for a calculated column should work:

Display Name =
IF (
    myTable[dimension code]
        IN {
        "Code 123",
        "Code 456"
    },
    myTable[dimension discription]
)

 

If you need any help please let me know.
If I answered your question I would be happy if you could mark my post as a solution ✔️ and give it a thumbs up 👍
 
Best regards
Denis
 

View solution in original post

2 REPLIES 2
selimovd
Super User
Super User

Hey @jellis1971 ,

 

I didn't fully understand how you want to add the description. Can you explain that better?

If the description exists in a column and you only want to change the visibility, the following approach for a calculated column should work:

Display Name =
IF (
    myTable[dimension code]
        IN {
        "Code 123",
        "Code 456"
    },
    myTable[dimension discription]
)

 

If you need any help please let me know.
If I answered your question I would be happy if you could mark my post as a solution ✔️ and give it a thumbs up 👍
 
Best regards
Denis
 

Hi Denis:

It is kind of like what you said.  The dimension code is "Facility", and I'd like for the dimension values for "Facility" to display instead of the ones for other dimension codes such as "Region".

jellis1971

Helpful resources

Announcements
May 23 2022 epsiode 5 without aka link.jpg

The Power BI Community Show

Welcome to the Power BI Community Show! Jeroen ter Heerdt talks about the importance of Data Modeling.

charticulator_carousel_with_text (1).png

Charticulator Design Challenge

Put your data visualization and design skills to the test! This exciting challenge is happening now through May 31st!

Power BI Dev Camp Session 22 with aka link 768x460.jpg

Check it out!

Mark your calendars and join us on Thursday, May 26 at 11a PDT for a great session with Ted Pattison!

Power BI Release May 2022 768x460.png

Check it out!

Click here to read more about the May 2022 updates!