Formula to count the number of characters after a symbol
Hello. I am attempting to write a formula that will count the number of characters that follow a "", and use the resulting number to determine if the type should be a "PO" or a "SWA" using an IF statement.
I found a formula that will pull those characters following the "", but it just gives me the actual 2 numbers following the dash, what I need to write the formula is:
IF (PO/SWA No@row) = 2 characters, "PO", otherwise "SWA"
Best Answer

Oh I see... Try this rendition.
=IF(LEN(RIGHT([PO / SWA No]@row, LEN([PO / SWA No]@row)  FIND("", [PO / SWA No]@row)))=2, "PO", "SWA")
Answers

Try this: =IF(LEN([PO / SWA No]@row)=2, "PO", "SWA"
For more on the LEN Function see:

Hi @Mike Wilday , I tried that out but the formula returns the same Agreement Type every time, no matter the digits after the dash:
This is the formula I am using in row 1 that I have been attempting to modify to reach my desired end point: =RIGHT([PO / SWA No]@row, LEN([PO / SWA No]@row)  FIND("", [PO / SWA No]@row))

Oh I see... Try this rendition.
=IF(LEN(RIGHT([PO / SWA No]@row, LEN([PO / SWA No]@row)  FIND("", [PO / SWA No]@row)))=2, "PO", "SWA")

Great, that worked, thanks for your help!

Awesome, glad I could help you out.
Help Article Resources
Categories
Check out the Formula Handbook template!