Executing a Stored Procedure Through Q+E May Cause UAELast reviewed: November 2, 1994Article ID: Q76229 |
SUMMARYExecuting a Stored Procedure on a SQL Server with two identical parameters from a macro in Excel 3.0 may cause an Unrecoverable Application Error (UAE) under Windows or a Protect Mode Violation under OS/2.
MORE INFORMATION
Steps to Reproduce ProblemTo duplicate this problem, run the following macro:
A2: =ACTIVATE("SHEET1") A3: =DB.LOGON("sqlserver") A4: =DB.SQL.QUERY(2,"use pubs; sp_helpjoins ''publishers'', ''authors''",1,false)* A5: =RETURN()QE.XLA must be loaded prior to running this macro. The quotation marks around the table names in the DB.SQL.QUERY statement are two sets of single quotation marks. The entire argument is enclosed in one set of double quotation marks. The following macro, which uses the DDE Execute command equivalents, will also fail. This macro does not require QE.XLA to be loaded.
A2: chan=INITIATE("QE","SYSTEM") A3: =EXECUTE(chan,"[LOGON('sqlserver')]") A4: =ACTIVATE("sheet1") A5: =EXECUTE(chan,"[OPEN('use pubs; sp_helpjoins ''publishers'', ''authors''')]") A6: =EXECUTE(chan,"[COPY.SPECIAL(TRUE,FALSE,1,2)]") A7: =PASTE() A8: =TERMINATE(chan) A9: =RETURN()When executed, these macros start Q+E and bring up the SQL Server LOGON dialog box. After logging on, Q+E starts to perform the query and then generates a UAE. This problem has been corrected in the version of Q+E that was released with Excel 4.0.
REFERENCES"Q+E for Microsoft Excel User's Guide," pages 70, 90-100
|
KBCategory: kbother
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |