SOLVED

# Calculated coulmn : Check if a column value or a part of it matches specific text

Copper Contributor

# Calculated coulmn : Check if a column value or a part of it matches specific text

Please any support what is wrong in this formula in this single column calculated column I need it to look in Title Column  if it contains this word in the text (YCC) it fill the calculated column as (YCC) and the same for INDO Cement.

5 Replies
best response confirmed by Ghada Mehrez (Copper Contributor)
Solution

# Re: Calculated coulmn : Check if a column value or a part of it matches specific text

@Ghada Mehrez There's no Contain function in a SharePoint calculated column, you'd need to use Find. But the formula is going to be complicated if you are trying to see if the Title column contains YCC or INDO cement and puts in the relevant Text. What would be easier is to use 3 calculated columns:

YCC: =IF(ISERROR(FIND("YCC",Title)),"","YCC")

INDO: =IF(ISERROR(FIND("INDO Cement",Title)),"","INDO Cement")

Then combine the results of those into a third calculated column:

YCC OR INDO:  CONCATENATE([YCC], [INDO])

Then just hide the YCC and INDO columns.

Rob
Los Gallardos
Intranet, SharePoint and Power Platform Manager (and classic 1967 Morris Traveller driver)

# Re: Calculated coulmn : Check if a column value or a part of it matches specific text

Thanks a lot it works now:)

# Re: Calculated coulmn : Check if a column value or a part of it matches specific text

Hi Rob, I used this formula below... It seemed to work until my list grew.  Is this true that there is a Limit of the number of columns I want to combine.

# Re: Calculated coulmn : Check if a column value or a part of it matches specific text

Ok just found that you can only have up to 30 Items.
Any way of doing more?

# Re: Calculated coulmn : Check if a column value or a part of it matches specific text

Found a work around. Did 2 columns one with 30 items and one with 20.
Then combined the 2 for my final result.
1 best response

Accepted Solutions
best response confirmed by Ghada Mehrez (Copper Contributor)
Solution

# Re: Calculated coulmn : Check if a column value or a part of it matches specific text

@Ghada Mehrez There's no Contain function in a SharePoint calculated column, you'd need to use Find. But the formula is going to be complicated if you are trying to see if the Title column contains YCC or INDO cement and puts in the relevant Text. What would be easier is to use 3 calculated columns:

YCC: =IF(ISERROR(FIND("YCC",Title)),"","YCC")

INDO: =IF(ISERROR(FIND("INDO Cement",Title)),"","INDO Cement")

Then combine the results of those into a third calculated column:

YCC OR INDO:  CONCATENATE([YCC], [INDO])

Then just hide the YCC and INDO columns.

Rob
Los Gallardos
Intranet, SharePoint and Power Platform Manager (and classic 1967 Morris Traveller driver)