title | description | author | ms.author | ms.reviewer | ms.date | ms.service | ms.subservice | ms.topic | helpviewer_keywords | |
---|---|---|---|---|---|---|---|---|---|---|
MSSQLSERVER_3988 |
MSSQLSERVER_3988 |
suresh-kandoth |
sureshka |
vencher, tejasaks, docast |
12/25/2020 |
sql |
supportability |
reference |
|
[!INCLUDE SQL Server]
Attribute | Value |
---|---|
Product Name | SQL Server |
Event ID | 3988 |
Event Source | MSSQLSERVER |
Component | SQLEngine |
Symbolic Name | XACT_UNSUPPORT_PARALLEL_TRAN2 |
Message Text | New transaction is not allowed because there are other threads running in the session. |
This error occurs when you execute a distributed query that joins multiple tables hosted by remote instances of [!INCLUDEssNoVersion] while the XACT_ABORT
session setting is ON. An error message similar to the following is reported to the user:
Msg 3988, Level 16, State 1, Line #
New transaction is not allowed because there are other threads running in the session.
There are some design limitations in the way [!INCLUDEssNoVersion] handles distributed queries (DQs) when the following conditions are true:
- SQL Server joins multiple tables of one remote [!INCLUDEssNoVersion] data source.
- The session that is issuing the query is not enlisted in a distributed transaction.
In this situation, an attempt to run the query may raise either of the two errors that are mentioned in the Explanation section.
To work around the issue, enclose the distributed query in a 'begin distributed transaction' statement:
BEGIN DISTRIBUTED TRANSACTION
/*The actual Distributed Query goes next, outside of comments*/
COMMIT TRANSACTION