View Single Post
  #4   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Peter Jamieson Peter Jamieson is offline
external usenet poster
 
Posts: 4,582
Default Mail Merge to SQL Server without using an external ODC

Did you work out how to do the ODBC connection?

Honestly, I think this is another of those
situations where Microsoft didn't have *anything* in mind.


I certainly don't understand why they insist that you have an external
object of some kind and don't allow DSN-less and ODC-less connections,
unless of course they were
a. worried that the end result would be loads of .doc files with embedded
plain text login/password info.
(but if you're using SQL Server integrated security that's wouldn't be an
issue anyway)
or
b. worried that then people would be able to distibute their merge
qapplications reasonably easily :-)

Peter Jamieson

"Graham" wrote in message
oups.com...
Cindy M.
wrote:
Hi Graham,

Is there any way to embed the SQL Server connection information right
into a Word document?


Which version of Word are we discussing? And do your systems have an ODBC
driver for SQL Server installed?

I think it can't be done for OLE DB, as this also requires an external
*.odc file. ODBC can probably do it. And a macro that links the data
source when the file opens could probably work.

Another possibility (and it's what MSFT had in mind when they designed
the interface) would be to distribute the *.odc file for the connection
to everyone's "My Data Source" folder.

Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update Jun 17 2005)
http://www.word.mvps.org


Word 2003, and all Microsoft systems have the SQL ODBC driver
installed.

The distribution path you describe would require an installer, which is
a heck of a lot of trouble to get a 25-character connection string down
to the users' machines. Honestly, I think this is another of those
situations where Microsoft didn't have *anything* in mind.

g.