Increment an internal prefixed sequence
Turn AB000001 into AB000002, zeros kept, for your own internal codes.
What you'll make

The formula

| Number | Part | What it does | Result so far |
|---|---|---|---|
| 1 | LEFT(A8,2) | Keeps the two letters at the start. | "AB" |
| 2 | VALUE(RIGHT(A8,6))+1 | Reads the last six digits as a number and adds 1. | 2 |
| 3 | TEXT( … ,"000000") | Writes it back as six digits, zeros in front. | "AB000002" |
Read it left to right; part 3 works on part 2. The codes here are made-up.
=LEFT(A8,2)&TEXT(VALUE(RIGHT(A8,6))+1,"000000")How to use it
Yellow bar at the top? Click Enable Editing.
- See it work. The Example tab shows 20 made-up examples with the formula already in.
- Use your own codes. Paste codes, stored as text, into the green column of the Template tab. The next codes fill in by themselves.
- Move them into your letter. Copy the results. Then use Paste Special and choose Values.
Before you send
Use this only for your own internal codes. Never add one to an NPI, TIN or any ID someone else assigns.
Microsoft's help: TEXT function
OTHER ROUTES YOU MIGHT LIKE

Read the numeric sequence from a code
AB000123 → 123
Get the template →
Read an ID at the end of a web address
https://example.test/provider/000123?view=full → 000123
Get the template →
Read an ID by name from a web address
example.test/p?providerId=000123&view=full + providerId → 000123
Get the template →
Merge a few test letters before the whole mailing
Whole mailing → records 2 to 4 only
Take this route →