FIX: Update Queries with OpenXML Table Aliases Cause Access Violation (292454)



The information in this article applies to:

  • Microsoft SQL Server 2000 (all editions)

This article was previously published under Q292454
BUG #: 236072 (SHILOH_BUGS)

SYMPTOMS

An access violation (EXCEPTION_ACCESS_VIOLATION) is caused when UPDATE .... FROM OPENXML type of queries are used with an alias. For example, a query with syntax similar to the following causes the access violation to occur:
UPDATE table_name SET column = values 
FROM OPENXML(...) range, table1 alias1 ...
				

RESOLUTION

To resolve this problem, obtain the latest service pack for SQL Server 2000. For additional information, click the following article number to view the article in the Microsoft Knowledge Base:

290211 INF: How to Obtain the Latest SQL Server 2000 Service Pack

WORKAROUND

If the alias name is removed from the UPDATE... FROM OPENXML query, the access violation no longer occurs.

STATUS

Microsoft has confirmed that this is a problem in SQL Server 2000. This problem was first corrected in SQL Server 2000 Service Pack 1.

MORE INFORMATION

Here is a short stack dump from the SQL error log:

-------------------------------------------------------------------------------
Short Stack Dump
00692778 Module(sqlservr+00292778) (CXMLTableMap::SetOpenXMLSchema(class IMemObj *,struct COLUMNDATANODE *,class CXVariant *,int,struct IXMLDOMDocument *)+000001AD)
0069244C Module(sqlservr+0029244C) (COpenXMLRange::GetRowset(class CExecContext *,int)const +00000202)
0070F889 Module(sqlservr+0030F889) (CQScanRmtScan::OpenConnection(void)+00000141)
0070ECA9 Module(sqlservr+0030ECA9) (CQScanRmtBase::Open(unsigned long *)+00000018)
00436088 Module(sqlservr+00036088) (CQScanHashMatch::Iterate(unsigned long *)+00000823)
00439512 Module(sqlservr+00039512) (CQScanHashMatch::Open(unsigned long *)+0000006C)
00436088 Module(sqlservr+00036088) (CQScanHashMatch::Iterate(unsigned long *)+00000823)
00439512 Module(sqlservr+00039512) (CQScanHashMatch::Open(unsigned long *)+0000006C)
0042AB42 Module(sqlservr+0002AB42) (CQScan::Open(unsigned long *)+0000001C)
0042FE72 Module(sqlservr+0002FE72) (CQScanTop::Open(unsigned long *)+0000000E)
0042AB42 Module(sqlservr+0002AB42) (CQScan::Open(unsigned long *)+0000001C)
004C0030 Module(sqlservr+000C0030) (CQScanUpdate::Open(unsigned long *)+000000C8)
00428749 Module(sqlservr+00028749) (CQueryScan::Startup(unsigned long *,class BaseXact *)+00000111)
0042703D Module(sqlservr+0002703D) (CStmtQuery::ErsqExecuteQuery(class CMsqlExecContext *,class CEsComp const *,class CEsComp const *,unsigned long *,int,int)const +000002B5)
0042EA36 Module(sqlservr+0002EA36) (CStmtDML::XretExecuteNormal(class CMsqlExecContext *)const +000002F0)
0042E82D Module(sqlservr+0002E82D) (CStmtDML::XretExecute(class CMsqlExecContext *)const +0000001C)
004160DB Module(sqlservr+000160DB) (CMsqlExecContext::ExecuteStmts(class ExecutionContext *)+0000027E)
00415765 Module(sqlservr+00015765) (CMsqlExecContext::Execute(class CCompPlan *,class CParamExchange *)+000001C7)
00415410 Module(sqlservr+00015410) (CSQLSource::Execute(class CParamExchange *)+00000343)
00459A54 Module(sqlservr+00059A54) (language_exec(struct srv_proc *)+000003C8)
004175D8 Module(sqlservr+000175D8) (process_commands(struct srv_proc *)+000000E0)
410735D0 Module(UMS+000035D0) (ProcessWorkRequests(class UmsWorkQueue *)+00000264)
4107382C Module(UMS+0000382C) (ThreadStartRoutine(void *)+000000BC)
7800BEA1 Module(MSVCRT+0000BEA1) (_beginthread+000000CE)
77E92CA8 Module(KERNEL32+00012CA8) (CreateFileA+0000011B)
-------------------------------------------------------------------------------

				

Modification Type:MajorLast Reviewed:11/6/2003
Keywords:kbBug kbfix kbSQLServ2000sp1fix KB292454