>>Ed,
>>
>>I think it's very hard to achieve what you're trying to achieve and probably not worth the effort. Your Order number should be a unique key and user should not even see it. If the later is the case, then it doesn't matter if some numbers are skipped.
>
>The Order number should not be the primary key. It should be visible to the users, just as an invoice number should be visible to the users. The primary key/foreign key should not be visible to the user.
>
Ok. Then I still don't see a solution to the problem to keep numbers without holes.
If it's not broken, fix it until it is.
My Blog