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
Apple08
Helper IV
Helper IV

Lookup multiple values in a column

Hi All

 

I need a DAX to look up the values in column A then create another column B as shown below.  

 

I know I can use if(search in DAX however I just wonder is there a quicker way like something to group them with 'Or', e.g. if(or(search"Apple", "apple").... to be more effective?  Many thanks.

 

Column AColumn B
AppleApple
appleApple
BoyBoy
boy is playingBoy
GirlGirl
Playing (girls)Girl
I prefer not to sayNot known
Not knownNot known
OtherOther
5 REPLIES 5
Anonymous
Not applicable

Hi @Apple08,

Perhaps you can use 'upper' or 'lower' or not 'case sensitive' function to processing the feild strings before check it, they should help you to skip some simple difference in search.

UPPER function (DAX) - DAX | Microsoft Learn 

LOWER function (DAX) - DAX | Microsoft Learn

SEARCH function (DAX) - DAX | Microsoft Learn

Then you can setting a default values to the search result with if statement to handle 'not found' results.

Regards,

Xiaoxin Sheng

Apple08
Helper IV
Helper IV

Thanks, I like a DAX to include the rest as well, e.g. 'Girl' or 'playing (girls) then 'Girl'

Smalfly
Responsive Resident
Responsive Resident

Then the SWITCH function is what you are looking for:

https://learn.microsoft.com/en-us/dax/switch-function-dax

 

I wonder search function is more appropriate to look for any specific value within the text.  As I need to look for the specific value within long text.

Smalfly
Responsive Resident
Responsive Resident

Hi @Apple08 ,

 

You can use the in function.

So, if ColumnA in {"Apple", "apple"} then 'Apple'

 

Is that what you are looking for?

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.

Top Solution Authors
Top Kudoed Authors