Word mailmerge using Access file

D

Dig

I have a friend who is using Word2K. He gave me a list of names for a
mailing and asked me if I could clean the list and sort the list according
to zip.

I did all the work in Access 2K and sent him the access mdb file. He opened
it in using the mailmerge tool in word and setup all the fields for the
labels. When he previewed it the list was in alphabetical order.

So I opened the same list in my Word2k and it was sorted by zip.

Any ideas why his version (which I had emailed him) is resorting to alpha
instead of by zip?

Driving me crazy.
Thanks
 
P

Peter Jamieson

Something to bear in mind is that records in a Jet (Access) database table
(or any other truly relational database table) have no natural, predefined
sequence - in orther words, when an application issues a query such as

SELECT * FROM mytable

(which is in essence what Word is doing)

there is no guarantee that the records will be returned in any particular
sequence. Not even the sequence of the primary key (which I think a lot of
people might assume is the "natural" sequence).

To ensure a particular sequence, you have to use an ORDER BY clause in the
SQL, and typically the easiest way to do that in this situation would be to
create an Access query with a particular sort sequence defined, and use that
as the data source for the merge.

(However, I would agree that there is no obvious reason why the records
/should not/ appear in the same sequence, even if they are not guaranteed to
do so).
 
D

Dig

Thanks Peter for the help.

A couple of quick questions if I may.
1.) Would it help to convert the file to a delimited file? Export it out of
Access as a comma delimited file with quotes.

2.) If I should stay with the Access file are you saying to use a Query and
sort on the zip field and let Word use the query as the file?

Thanks
 
D

Doug Robbins - Word MVP

Hi Dig,

You would be better to stay with Access and use the query as the datasource.
It will always then display the latest information.

Please post any further questions or followup to the newsgroups for the
benefit of others who may be interested. Unsolicited questions forwarded
directly to me will only be answered on a paid consulting basis.

Hope this helps
Doug Robbins - Word MVP
 
P

Peter Jamieson

Both approaches should work, but Word sometimes has trouble recognising
delimited files correctly and the second choice seems more straightforward
to me.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top