Results 1 to 3 of 3

Thread: Auto numbering

  1. #1
    Join Date
    Jun 2006

    Unanswered: Auto numbering

    I see from reading through the posting that auto numbering in NOT the way to go if you need sequential numbers. I have an Access database set up to print labels for our products that also assign a Serial Number (using auto numbering in access) and it has recently starting skipping and/or repeating numbers. What would be the best way for me to have this database assign sequential numbers to the labels?

  2. #2
    Join Date
    Jul 2003
    I'd create a table to hold the value of the number. Whenever I needed a new label, I'd add 1 to the stored number, then use the new number on my label.
    Inspiration Through Fermentation

  3. #3
    Join Date
    Dec 2002
    Préverenges, Switzerland
    in case it helps, here is a demo of something along the lines of RNG's suggestion with the addition of an optimistic lock scheme to prevent two users getting the same serial. the 'magic trick' is the obscure one-record table.

    currently using SS 2008R2

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts