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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
LaurentZ
Helper I
Helper I

AutoFill from the Left

Dear All,

Thank you for taking the time to read this.

 

In my Query I've this kind of Data

Type1   Type2   Type3     NEW COL
AA         BB                         BB
CC         DD         EE            EE

 

I would like to add a new column that does the follwing:

(if type3 ="" then (if type 2 ="" then type 1 else type 2) else type 3)

 

the reason is that I want to map and merge with another table 

Mapping Table
BB   BALI-BALO
EE    ELI-ELO

 

Is this possible ?

Regards,

Laurent

1 ACCEPTED SOLUTION
VasTg
Memorable Member
Memorable Member

@LaurentZ 

 

Create a custom column in Edit queries as below

 

= if [Type3] = "" and [Type2] = ""  then [Type1] else if [Type3] = "" then [Type2] else [Type3]

 

 image.png

 

If it helps, mark it as a solution

Kudos are nice too

Connect on LinkedIn

View solution in original post

3 REPLIES 3
VasTg
Memorable Member
Memorable Member

@LaurentZ 

 

Create a custom column in Edit queries as below

 

= if [Type3] = "" and [Type2] = ""  then [Type1] else if [Type3] = "" then [Type2] else [Type3]

 

 image.png

 

If it helps, mark it as a solution

Kudos are nice too

Connect on LinkedIn

Thank you @VasTg . It works like a charm !

@LaurentZ 

 

Glad it helped.

 

Connect on Linkedin 

Connect on LinkedIn

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

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

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.