Extract Data from table for Mailing Lables

S

Scoop

I have a database that I import into Access XP, it is a tab delimited file
that is imported into an access table, let's call it DATA_TABLE. It is in
the format:

Name HairColor EyeColor ShoeSize ShirtSize
Bill Brown Brown 9.5 M
Tom Brown Blue 10.5 XL
Jack Black Brown 8.0 M
Ed Blonde Blue 11.0 XXL
. . .

What I need to do is extract certain elements from the table in order to
make mailing labels. For example, I want to make mailing lables to only
those that have an M ShirtSize without regard for any other element. In the
same fashion I would want to make mailing labels for only those with
HairColor Blonde *and* ShirtSize XL. (Please assume that one of the fields
is address, the above sample table is only for reference) In other words, I
only want to print the mailing labels targeted to a specific group contained
in the table based on certain factors and conditions being met.

i.e.
If HairColor == "Black" &
EyeColor == "Brown" then
PrintLabels;
else DontPrintLabel.

Ideally, a separate mailing label file will be created that I can then just
print in either Access, Word, .pdf, whatever. For example, I would want a
few files created based on the sort:

BlackHair.pdf
BlueEyes.pdf
ShoeSize8.pdf
BlueEyesBlackHair.pdf

By double clicking on BlackHair.pdf Acrobat would open and the mailing
labels for everyone in table DATA_TABLE with HairColor=Black would be ready
to print on the mailing lables.

I don't even know if there is some other tool/database out there that may
accomplish this easier. Thank you in advance for any assistance with this
problem.
 
J

John Nurick

Hi Scoop,

The way to do this is to use a Query based on your table. This lets you
select records from the table based on any combination of criteria.

Then, to make the labels, click on Reports in the Database Window, and
then on the New button. This brings up the New Report wizard; select
"Label Wizard" and work through it to create an Access report that
prints labels from your Query.

To use this with different criteria, all you have to do is go back to
the Query and change the criteria there, then run the report again.

You can either print the report directly to paper labels, or else print
it to a PDF file (using Acrobat Distiller or whatever other PDF software
you usually use).

With a little more work and knowledge of Access, this can be set up to
make it even easier to select the criteria you want and generate the
labels as and when you need them, rather than using PDF files as
"intermediaries".


I have a database that I import into Access XP, it is a tab delimited file
that is imported into an access table, let's call it DATA_TABLE. It is in
the format:

Name HairColor EyeColor ShoeSize ShirtSize
Bill Brown Brown 9.5 M
Tom Brown Blue 10.5 XL
Jack Black Brown 8.0 M
Ed Blonde Blue 11.0 XXL
. .

What I need to do is extract certain elements from the table in order to
make mailing labels. For example, I want to make mailing lables to only
those that have an M ShirtSize without regard for any other element. In the
same fashion I would want to make mailing labels for only those with
HairColor Blonde *and* ShirtSize XL. (Please assume that one of the fields
is address, the above sample table is only for reference) In other words, I
only want to print the mailing labels targeted to a specific group contained
in the table based on certain factors and conditions being met.

i.e.
If HairColor == "Black" &
EyeColor == "Brown" then
PrintLabels;
else DontPrintLabel.

Ideally, a separate mailing label file will be created that I can then just
print in either Access, Word, .pdf, whatever. For example, I would want a
few files created based on the sort:

BlackHair.pdf
BlueEyes.pdf
ShoeSize8.pdf
BlueEyesBlackHair.pdf

By double clicking on BlackHair.pdf Acrobat would open and the mailing
labels for everyone in table DATA_TABLE with HairColor=Black would be ready
to print on the mailing lables.

I don't even know if there is some other tool/database out there that may
accomplish this easier. Thank you in advance for any assistance with this
problem.

John Nurick [Microsoft Access MVP]

Please respond in the newgroup and not by email.
 
Top