>That's all well and good for single users and lans, but you cannot use the same strategy if you have a distributed app. For example a multi-lan wan, that may not be on-line all the time with a central location, that keeps a master invoice file. With my way of gen'ing unique numbers all I have to do is add a location/machine id to sys(2015)and I'm done.
>//:^)
Larry,
In that case I would use a table for the ids for eacht able. Each record represents a single new key value and it has a field that stores its status, assigned to a record, ckecked out to a station but not yet assigned to a record , and fully available.
You can also use the same scheme you are using except that you use a character field of 6 byte, the first two are station id and user followed by a four byte integer. Just make the field Character Binary to prevent collation form messing with the binary data.