The counter used to generate serial numbers for this part has reached its maximum

Any help on this error? I’m not a serial number expert and one of our users changed a serial prefix for the year change. I was told he did this when there were parts with old format SN’s already assigned to jobs in WIP, but none were in stock so he was able to change it on both the part header and the site tab, but now he gets this error when trying to assign a new SN to a new job.

Prefix is set for 9622 and it’s a 4 digit serial number with leading zeros. Nothing else is enabled.

For reference last SN that was assigned to that part was 96212109

So you only have 4 digits for the numeric part of your serial number. You are trying to go past 96229999.

I’m not sure if it will work but you can try to change the Number of Digits from 4 to 5. If it works, your serial numbers will now be 9 digits. Make sure labels and other stuff work.

If that doesn’t work, you may have to create a Mask with a higher number of digits and then assign that here.

1 Like

There are no SN’s that exist with 9622 prefix. It was just changed to this prefix and the last SN assigned to a job for that PN was 96212109. The next SN that I expect them to be generating is 96220001. I looked back in all generated SN’s and each year prefix change it starts back up at 0001 for the first part of the year.

I’ve been told they do this every year, but clearly something different happened to cause this error. I’m just lucky enough to be the guy who has to find a way to fix it after it’s broken.

Unless something has changed, it doesn’t care what the prefix is. Once the counter overflows, you’re done. It doesn’t roll over and I’m not sure why. But I’ve never been able to reset the counter before. :person_shrugging:

The only way around it that I’ve found was to define a Mask (the same way as the part), assign it to the part, use the Mask sequence numbers, and then start the counter over.

I could understand that if there were only 9999 parts ever made with SN’s but since 2013 when they started tracking this part they have generated 12625 Serial numbers, each year the prefix changing and the 4 digit number starting over again.

We can’t change the SN format, length, due to a customer requirement, there has to be a way to fix this otherwise this is a ridiculous problem with Epicor that I can not believe no one has found yet.

1 Like

Yeah, if you didn’t roll it for real then it’s definitely an Epicor issue.

Could someone have accidentally put in a large number in the quantity (like a date) to blow through the remaining serial numbers? :thinking:

And the Mask solution is always a backup plan that will work for you.

If serial numbers use the NextValue API, and you’re on prem, and you determine that someone did blow through all the remaining serial numbers, you could find the counter in the database and reset it. I don’t remember the table names that NextValue uses, but I remember them being easy to find by querying sys.tables and sys.columns.

Check ice.SysSequence

Serial Number counters are in Part.SNLastUsedSeq or, if you use a Serial Number Mask, SerialMask.SNLastUsedSeq.

Why would this coincide with them changing the prefix though? It’s not like it just started when they were assigning a number, it happened immediately after they changed the prefix on multiple different PN’s.

Are you certain somebody wasn’t zeroing out the counter through SSMS or even a BPM on a change in the prefix that zeroed out the counter?

No body has the rights or knowledge on how to do that… Including myself.

What does Part.SNLastUsedSeq say right now?

Part Starting Sequence Base Number Structure Serial Mask Mask Example Mask Prefix Mask Suffix Serial Number Prefix
FTIIP21253 INTEGER 9622

Here are the 4 affected parts… the one at the bottom of the list is the only one that currently allows them to assign SN’s.

Part Starting Sequence Base Number Structure Serial Mask Mask Example Mask Prefix Mask Suffix Serial Number Prefix
FTIIP21253 INTEGER 9622
FTIIP23176 INTEGER 0822
FTIIP23977 INTEGER 2422
FTIIP25275 INTEGER P9622

Can you do a BAQ and display the PartNum and SnLastUsedSeq fields for these parts?

*** Part is the only table required ***

That’s what the above BAQ is, SnLastUsedSeq is labeled as “starting sequence”

It’s empty? :thinking:

Let’s try PartPlant.

I know you were hoping for it to be different… but it’s not…

Part SN Prefix Starting Sequence
FTIIP21253 9622
FTIIP23176 0822
FTIIP23977 2422
FTIIP25275 P9622

Yep, because that means you’re going to have to call Epicor.