I have everything working except two examples that don't match anything in your description:
4560116-0010
3931212-0030
Your description says:
Basically batch numbers are either in the format A1234, 1234-1234567, or numbers with lengths of 10 or 12 digits. The first two should be as they are, as should the ones with LEN = 12. However all other numbers in the string with LEN from 5 to 10 should be returned with 0’s before so they all have LEN = 10 so 12345 => 0000012345.
but you don't say anything about 1234567-1234.
Can you clarify what you need here?
Bookmarks