How do I get the characters before a specific character?

Let's say I have column username where the drop down is a list. A username is "JonSmith-81". I'd like the next line item, lets call it alias, to just pull "JonSmith" from this string. The alias line item is formatted as text. What would be the formula to return just "JonSmith" in alias line item? I seem to get an error due to the mismatch in formatting.

Answers