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

July 7 - July 17 | Round 2 of the Power BI Dataviz World Championships. Don't miss your chance! Learn more

Reply
mithiladas02
Helper I
Helper I

Replace value

I have table like below

when i try to replace value  From Source field- Linkdln, it is changing social media- Linkdln also. How can i change only jobboards-linkdln name? 

Source CategorySource
Social MediaLinkdln
JOb Boardsjob street
JOb boardsLinkdln

 

 

How can i show below table in power query?

 

Source CategorySource
Job BoardsJob Boards-Linkdln
Social MediaLinkdln
Job BoardsJob Street
2 ACCEPTED SOLUTIONS
amitchandak
Super User
Super User

@mithiladas02 , A new column in power query

if [Source Category] = "Job Boards" and [Source]="Linkdln" then [Source Category] & "-" & [Source] else [Source Category]

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

View solution in original post

Pragati11
Super User
Super User

Hi @mithiladas02 ,

 

Try something as follows in Power Query editor in Power BI.

 

This is the data:

Pragati11_0-1644935557984.png

 

Now under Add Column:

Pragati11_1-1644935649598.png

 Then a new window appears:

Pragati11_3-1644936142812.png

 

Formula that I have written can be seen below in editor window:

if 
   ([Source Category] = "JOb boards" 
   and [Source] = "Linkdln") 
   then "Job Boards-Linkdln" 
   else [Source]

You will get following:

Pragati11_4-1644936175430.png

Just remove the Source column:

Pragati11_5-1644936207227.png

Modify data-type of New Source to text and rename it to Source. You will get required results:

Pragati11_6-1644936261360.png

 

Thanks,

Pragati

 

Best Regards,

Pragati Jain


MVP logo


LinkedIn | Twitter | Blog YouTube 

Did I answer your question? Mark my post as a solution! This will help others on the forum!

Appreciate your Kudos!!

Proud to be a Super User!!

View solution in original post

2 REPLIES 2
Pragati11
Super User
Super User

Hi @mithiladas02 ,

 

Try something as follows in Power Query editor in Power BI.

 

This is the data:

Pragati11_0-1644935557984.png

 

Now under Add Column:

Pragati11_1-1644935649598.png

 Then a new window appears:

Pragati11_3-1644936142812.png

 

Formula that I have written can be seen below in editor window:

if 
   ([Source Category] = "JOb boards" 
   and [Source] = "Linkdln") 
   then "Job Boards-Linkdln" 
   else [Source]

You will get following:

Pragati11_4-1644936175430.png

Just remove the Source column:

Pragati11_5-1644936207227.png

Modify data-type of New Source to text and rename it to Source. You will get required results:

Pragati11_6-1644936261360.png

 

Thanks,

Pragati

 

Best Regards,

Pragati Jain


MVP logo


LinkedIn | Twitter | Blog YouTube 

Did I answer your question? Mark my post as a solution! This will help others on the forum!

Appreciate your Kudos!!

Proud to be a Super User!!

amitchandak
Super User
Super User

@mithiladas02 , A new column in power query

if [Source Category] = "Job Boards" and [Source]="Linkdln" then [Source Category] & "-" & [Source] else [Source Category]

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Helpful resources

Announcements
FabCon and SQLCon Barcelona 2026

FabCon & SQLCon – Barcelona 2026

Join us in Barcelona for FabCon and SQLCon, the Fabric, Power BI, SQL, and AI community event. Save €200 with code FABCMTY200.

60 days of Data Days Carousel

Data Days 2026

Join Fabric Data Days 2026: 60 days of free live/on-demand sessions, challenges, study groups, and certification opportunities.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Top Solution Authors