467,877 Members | 1,205 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 467,877 developers. It's quick & easy.

Code "Auto-Letters" ?

Greetings:
I appoligize if I'm asking a question that's already been answered in
the group - I've scoured for about two hours and I can't find a
solution. I also appoligize if I over complicate my question, but I
want to be sure that I communicate my thought(s).

The database I'm working on will generate tens, perhaps hundreds of
thousands of records, each of which need to be identified uniquely.
Using the autonumber would be ideal except that I'll need to use this
unique field to generate barcodes which will have to be printed on
small labels. So - If I get to record 999,999 and generate a barcode
for it, the barcode will be huge - or to big to fit on my label.

I think my solution would be to use letters rather than numbers.
Instead of counting 1, 2, 3, 4... 1,000; I want to count A, B, C, D...
ABCD. I guess my logic can be flawed, but I was thinking that since
there are 26 letters in the alphabet and only 10 numbers, I would be
able to get quite a bit farther in each place value using letters.

Thanks a bunch for any suggestions!

Matt

Nov 13 '05 #1
  • viewed: 2747
Share:
3 Replies
ma**@1320am.com wrote in
news:11**********************@l41g2000cwc.googlegr oups.com:
Greetings: I think my solution would be to use letters rather than
numbers. Instead of counting 1, 2, 3, 4... 1,000; I want to
count A, B, C, D... ABCD. .

Thanks a bunch for any suggestions!

Matt

Use the autonumber in the table and write a function that takes the
modulo 36 (26Letters+ 0-9 digits) of your number and converts it to
a digit or letter and then loops to process the remaining value and
use that on your barcode..Sorta like Hex but with all letters of
the alphabet instead of just 0-9,A-F.

--
Bob Quintal

PA is y I've altered my email address.
Nov 13 '05 #2
Matt,
Mathematically all you are doing is counting a series that iterates by one
and has a base of 26. Once you generate the next number in the series it's
a simple matter of using the char(ansivalue) function to return the
character for that number. Now, a 15 digit number will give you a maximum
value of 999,999,999,999,999. That's a quadrillion rows in a single table
before you run out of numbers. Access won't hold a quadrillion rows, as far
as I know. So you'll run out of rows in your table before you run out of
numbers if you used a simple numeric sequence. You could still declare as a
15 character text column that held your sequence numbers. If I were you I'd
just use a numeric sequence of my own design. Even if you interated by ten
you'd still have over 100 billion numbers--plenty.

<ma**@1320am.com> wrote in message
news:11**********************@l41g2000cwc.googlegr oups.com...
Greetings:
I appoligize if I'm asking a question that's already been answered in
the group - I've scoured for about two hours and I can't find a
solution. I also appoligize if I over complicate my question, but I
want to be sure that I communicate my thought(s).

Nov 13 '05 #3
Matt,
It also occurs to me that the 2-D bar codes that UPS uses probably can fit
more values in the same small space because it uses a pattern of squares to
hold the data instead of a pattern of bars. This may not be a database
problem as much as it is a choice of bar code software problem.

<ma**@1320am.com> wrote in message
news:11**********************@l41g2000cwc.googlegr oups.com...
Greetings:
I appoligize if I'm asking a question that's already been answered in
the group - I've scoured for about two hours and I can't find a
solution. I also appoligize if I over complicate my question, but I
want to be sure that I communicate my thought(s).

The database I'm working on will generate tens, perhaps hundreds of
thousands of records, each of which need to be identified uniquely.
Using the autonumber would be ideal except that I'll need to use this
unique field to generate barcodes which will have to be printed on
small labels. So - If I get to record 999,999 and generate a barcode
for it, the barcode will be huge - or to big to fit on my label.

I think my solution would be to use letters rather than numbers.
Instead of counting 1, 2, 3, 4... 1,000; I want to count A, B, C, D...
ABCD. I guess my logic can be flawed, but I was thinking that since
there are 26 letters in the alphabet and only 10 numbers, I would be
able to get quite a bit farther in each place value using letters.

Thanks a bunch for any suggestions!

Matt

Nov 13 '05 #4

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

reply views Thread by Smyke | last post: by
1 post views Thread by PL | last post: by
1 post views Thread by JJ | last post: by
22 posts views Thread by nospam_news | last post: by
2 posts views Thread by Piotr K | last post: by
reply views Thread by MrMoon | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.