Why do some Word 2003 prompt for running a blank SQL command?

B

Bill Frog

I have a Labels type main document that has been saved before attempting to
open a data source. The users of this document like that it is a labels type
document because when it is opened, the Mailing Wizard automatically goes to
step 3.

Unfortunately some, but not all, Word 2003 users when they attempt to open
it, get the "Opening this document will run the following SQL command:" and
the command is blank. This is frustrating both for the users and for the
support desk. The affected users don't like getting the dialog when their
colleagues don't, and the help desk personnel doesn't like not knowing how to
prevent the dialog from occurring.

So far, the problem seems to occur only with Word 2003 in Windows XP
Professional SP2. It has not been reported with Word 2007. It does not seem
to be related to the version of Word 2003. The problem occurs with some, not
all, older version of Word 2003, and with some, not all, newer version of
Word 2003.

Based on previous postings, we looked for the Word/Options/NoSQLQuery
registry setting on the Word 2003 installations that do not have the problem
and it is not there. That's good because, for security reason, we do not
want to bypass the dialog for documents that do have a SQL query.

The users do not want the document saved as a Normal type main document as
suggested in another posting.

I just want to know what causes some Word 2003 installations to show the
dialog and other Word 2003 installations not to show the dialog. That would
allow me to provide information to the users and help desk that will prevent
the affected users feeling they are being discriminated against.
 
G

Graham Mayor

The warning was introduced by a security update at some level, so those
machines that don't display it are not fully updated.
You receive the "Opening this will run the following SQL command" message
when you open a Word mail merge main document that is linked to a data
source - http://support.microsoft.com/?kbid=825765. See also the Word macro
to toggle the registry setting referred to in that link at
http://www.gmayor.com/word_vba_examples.htm#SQL.

--
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
Graham Mayor - Word MVP


<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
 
B

Bill Frog

Graham,

Thank you for your reply. Your hypothesis that the problem is caused by a
Word 2003 security patch has merit, in that it explains why some, not all,
Word 2003 installations display the "Opening this document will run the
following SQL query:" dialog with a blank command.

But, if the same security check is built into Word 2007, as implied by the
referenced KB article, one would expect the dialog to always appear in Word
2007. The dialog does not appear on the Labels type main document with no
data source (blank SQL query) on any of our Word 2007 installations whether
on XP or on Vista. All of the computers in our network have automatic update
with critical Microsoft patches enabled.

This leads me to suspect that:
a. Some other setting is involved in how Word 2003 behaves,
b. The security patch was amended so that blank SQL query does not elicit
the dialog, and that change is in Word 2007 but not all patched Word 2003.

Again, thanks for the reply,
Bill Frog
 

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