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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
Anonymous
Not applicable

Result based on 2 columns

Hi,

I need to create a custom  Categeory = "BA" and "Place" ="" then "BA" else "".

 

image.png

2 ACCEPTED SOLUTIONS
amitchandak
Super User
Super User

@Anonymous , Try a new column like

 

if(not(isblank([Categeory])) && isblank([Place]), [Categeory], blank())

 

Based on highlighted column

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

BA_Pete
Super User
Super User

@Anonymous 

 

In Power Query, you would create a custom column as follows:

 

requiredColumn =
if [Categeory] <> null and [Place] = null then [Categeory] else null

 

 

@amitchandak has already provided the best DAX solution.

 

Pete



Now accepting Kudos! If my post helped you, why not give it a thumbs-up?

Proud to be a Datanaut!




View solution in original post

3 REPLIES 3
FrankAT
Community Champion
Community Champion

Hi @Anonymous ,

you can do it like this:

 

08-03-_2021_17-19-22.png

With kind regards from the town where the legend of the 'Pied Piper of Hamelin' is at home
FrankAT (Proud to be a Datanaut)

BA_Pete
Super User
Super User

@Anonymous 

 

In Power Query, you would create a custom column as follows:

 

requiredColumn =
if [Categeory] <> null and [Place] = null then [Categeory] else null

 

 

@amitchandak has already provided the best DAX solution.

 

Pete



Now accepting Kudos! If my post helped you, why not give it a thumbs-up?

Proud to be a Datanaut!




amitchandak
Super User
Super User

@Anonymous , Try a new column like

 

if(not(isblank([Categeory])) && isblank([Place]), [Categeory], blank())

 

Based on highlighted column

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
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.

Top Solution Authors