cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Anonymous
Not applicable

RE: Rename the filed values

Hi all,

 

i want to  rename the filed values  like

 

i have a filed 

Region:

EMEA

AsiaPacific

Americas    

 

now i want to rename   AsiaPacific  to APAC

 

how to do ? where to do ? 

 

Best

Chanty

2 ACCEPTED SOLUTIONS

First select the table you want to add column to, this is visible in the Fields pane to the right of Power BI desktop

Now select the menu "modeling" and select "new column"

Write a formula similar to:

MyNewColumn = switch(
        [old column name],
        "old value1", "new value 1",
        "old value 2", "new value 2"
)

 

Then you can change the slicer field to the new column name

View solution in original post

@Anonymous

 

This is in the query editor window. You are looking at the main window. The query editor where you did the Replace values earlier. It's that same menu.

 

image.png

 

View solution in original post

11 REPLIES 11
Arnault_
Resolver III
Resolver III

Hi @Anonymous,

 

You can change the value in the query editor "edit queries", then select the colum, right click and "Replace values".

You can also keep the original values and create a correspondance table and create a relationship between your tables.

Best

Anonymous
Not applicable

Got it. Now im able to edit and repalced the values in original column.

 

but if i want to keep original column and need to create other column with required changes?  how to create?

As suggested in my previous post, I would recommend to create a new table with original values in the first column and the new values in the second one. Then you create a relationship between the 2 tables. Finally, you will use the new field (2nd column) as a slicer.

@Anonymous

 

OK. You can duplicate the original column on the same menu (by clicking on the right button of the mouse above the column): 'Duplicate column'. Then you can do the replace values in the duplicated column and leave the original one as it was.

 

 

Anonymous
Not applicable

Thanks AlB  but i cant see duplicate column option 😞  

 

i tried  left side pannel - Data tab    - loaded tables is there  i selected the entire column -right click i didnt see duplicate duplicate.PNG

@Anonymous

 

This is in the query editor window. You are looking at the main window. The query editor where you did the Replace values earlier. It's that same menu.

 

image.png

 

Anonymous
Not applicable

Thanks 🙂  its quite simple sollution.

 

and bit confusing Navigations 🙂

 

 

Best

Suresh

First select the table you want to add column to, this is visible in the Fields pane to the right of Power BI desktop

Now select the menu "modeling" and select "new column"

Write a formula similar to:

MyNewColumn = switch(
        [old column name],
        "old value1", "new value 1",
        "old value 2", "new value 2"
)

 

Then you can change the slicer field to the new column name

Anonymous
Not applicable

Thanks  your solution worked  🙂

AlB
Super User
Super User

Hi @Anonymous

 

Please always show your sample data in text-tabular format in addition to (or instead of) the screen captures.

 

If I understand correctly, you can do this quickly in the query editor. Just click on the column with the right button of the mouse  and you'll get a menu. Choose "Replace values" and there just enter 'AsiaPacific' in 'Value to find' and 'APAC' in 'Replace with'

   

 

Anonymous
Not applicable

Hi 

 

im using as filter...  if i right click im unable to see replace values option 😞filter.PNG

Helpful resources

Announcements
June 2022 update 768X460.jpg

Check it out!

Click here to read more about the June 2022 updates!

Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

Power BI Dev Camp Session 23 768x460.jpg

Check it Out!

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

June 20 episode 7 with aka link 768x460.jpg

The Power BI Community Show

Join us on June 20 at 11 am PDT when Kim Manis shares the latest on Azure Synapse analytics, the Microsoft Intelligent Data Platform, and notable Power BI Updates from Microsoft Build 2022.

Top Solution Authors
Top Kudoed Authors