Excel Study · Module 5: Text functions
Class 40LEN: count characters
Intermediate1:49 videoFree
Every staff ID should have 7 characters, but some were typed short. LEN counts the characters in a cell: =LEN(A2) gives 7 for EMP1042. Fill it down and the short ones stand out.
Try this AI prompt
Works in ChatGPT, Gemini, Copilot or Claude.
In Excel, A2 has a staff ID that should be 7 characters long. Write a formula for D2 that shows Too short if it has fewer than 7 characters, otherwise OK.
The answer that works
✓ checked in Excel=IF(LEN(A2)<7,"Too short","OK")
AI can get Excel wrong. Paste its answer into Excel and test it before you trust it.