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

Score big with last-minute savings on the final tickets to FabCon Vienna. Secure your discount

Reply
Anonymous
Not applicable

find value s in Sting and copy add in to the column

I would like to Find  the way to populate a column manded on the String I search for 

Example 

ALL MEN
ALL WOMEN
ALL KID
ALL BOY

 

SEARCH value is MEN ,KID,WOMEN BOY 

 

DESIRED RESULT 

 

ALL MENMEN
ALL WOMENWOMEN
ALL KIDKID
ALL BOYBOY
2 ACCEPTED SOLUTIONS
Greg_Deckler
Community Champion
Community Champion

Try this:

 

Column = 
SWITCH(TRUE(),
    CONTAINSSTRING([Column1],"WOMEN"),"WOMEN",
    CONTAINSSTRING([Column1],"MEN"),"MEN",
    CONTAINSSTRING([Column1],"KID"),"KID",
    CONTAINSSTRING([Column1],"BOY"),"BOY",
    BLANK()
)


Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

View solution in original post

v-yuta-msft
Community Support
Community Support

@Anonymous ,

 

You can also create a calculate column using DAX below:

Result = RIGHT(Table1[Data], LEN(Table1[Data]) - SEARCH(" ", Table1[Data]))

Capture.PNG

Community Support Team _ Jimmy Tao

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
v-yuta-msft
Community Support
Community Support

@Anonymous ,

 

You can also create a calculate column using DAX below:

Result = RIGHT(Table1[Data], LEN(Table1[Data]) - SEARCH(" ", Table1[Data]))

Capture.PNG

Community Support Team _ Jimmy Tao

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Greg_Deckler
Community Champion
Community Champion

Try this:

 

Column = 
SWITCH(TRUE(),
    CONTAINSSTRING([Column1],"WOMEN"),"WOMEN",
    CONTAINSSTRING([Column1],"MEN"),"MEN",
    CONTAINSSTRING([Column1],"KID"),"KID",
    CONTAINSSTRING([Column1],"BOY"),"BOY",
    BLANK()
)


Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...
Anonymous
Not applicable

Thanks a lot, Greg this really helped 

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.