• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

IF functions to find text within a string

I want to find text within a string, want to return two values.



ASSET_DESCProduct
PASSENGER CARRIERCV =If a text contains "Carr" then CV otherwise MC
PLATINAMC
PULSARMC


I entered the below formula but it's not working.



Product = if(iserror(search("CAR",'Allocation dump required MP state'[ASSET_DESC])),"CV","MC")



Also, I wanted to add a column based on three column values.



PRODUCTLIVE_EXPBOM BUCKETCLASSIFICATION
MC/CVEXPirrespective of bucketNPA
MC/CVLIV6+NPA
MC LIVo or 10 to 1 bucket
MCLIV2 or 3 or 4 or 5 or 62 to 6 bucket
CVLIV0X bucket
CVLIV1 or 2 or 3 or 4 or 5 or 61 to 6 bucket
 
First formula shall be written as (adjust red part to relevant cell reference):
=IF(ISNUMBER(SEARCH("CAR",A2,1)),"CV","MC")

I didn't understand the second part of your request.
 
I assume this is DAX question. Please upload sample of your data model, along with manually inputted desired output. It's bit difficult to give you help without it.
 
Hi:

Something like this?

= if (Text.Contains("CAR",'Allocation dump required MP state'[ASSET_DESC]) then "CV" else "MC")

Thanks
 
Back
Top