What you will practise
A positive instance counts delimiters from the left; a negative instance counts from the right. Matching is case-sensitive by default. Supply an explicit not-found value for records that may not contain the delimiter. Delimiters are literal text, not wildcards.
TEXTBEFORE(text, delimiter, [instance], [match_mode], [match_end], [if_not_found])The syntax above is a guide. Read the data and each task to choose the right arguments for your formula.
3 exercises in this lesson
- Exercise 1 · answer in E10
Extract the account prefix before the first hyphen in A2.
- Exercise 2 · answer in E10
Extract everything before the final hyphen in A3; search with instance -1.
- Exercise 3 · answer in E10
Extract text before the first hyphen in A4, returning "Uncoded" if none is found.
Before you check your answer
- Keep the source data intact. Write your answer in the highlighted result cell. Changing a source value changes the question instead of solving it.
- Use the requested cells. Check the first and last row of a range and read its column heading. A plausible total can still come from the wrong data.
- Reference values that can change. A fixed number may match today's sheet. A cell reference keeps the formula connected when the source values change.
How the answer is checked
The workbook evaluates your formula against the requested result. It also checks the skill being practised and tests the formula with changed source data, so a fixed answer that happens to match is not enough.
Use progressive hints when you need help, then try the task again with fresh data. Correctly solving a step opens the next exercise.
The workbook opens with this skill selected. Work through the exercises at your own pace.