SQL Server Q&A

As a software engineer, I focus on .NET, especially asp.net, C#, WCF and so on, and I am also very interested in Search Engine Optimization.

Entries Tagged ‘problem’

FIX: Error message when you run a stored procedure that references a linked server that is linked to the local server itself in SQL Server 2005: “Transaction context in use by another session”

Symptoms
In SQL Server 2005, you create a linked server that is linked to the local server itself. This configuration is also known as a loopback linked server. Then, you create a stored procedure that contains a statement that resembles the following statement:

INSERT <LocalTable> EXEC <LinkedServer>.<ProcedureName>When you run the stored procedure, you receive the following error message:

Msg 3910, Level 16, State 2, Line 1
Transaction context in use by another session.Note This problem does not occur in Microsoft SQL Server 2000.
Resolution
This problem occurs because of a design change in SQL Server 2005.

BUG: You may receive an access violation error message when you try to run an SSIS package in SQL Server 2005

Symptoms
Consider the following scenario. In Microsoft SQL Server 2005, you try to run a SQL Server Integration Services (SSIS) package. The SSIS package transfers data between two instances of SQL Server 2005. In this scenario, you may receive an access violation error message. When this problem occurs, the Microsoft Windows Application log contains an event that documents the system error message. The system error message resembles the following:

DTExec.EXE – Application ErrorThe exception unknown software exception (0×40000015) occurred in the application at location 0×7ee8bd9e.Note This problem occurs when Lookup transformations that are in the SSIS package are executed in parallel.This problem does not occur when Lookup transformations that are in the SSIS package are executed sequentially.
Resolution
This problem occurs when Lookup transformations from multiple data flow tasks share the same cache area.Lookup transformations may share the same cache area when the textin the SQLCommand property of one Lookup transformationthat isin a data flow taskis the same asthe textin the SQLCommand property of a Lookup transformationthat is in another data flow task.

How do I open the firewall port for SQL Server on Windows Server 2008?

Symptoms
Windows Firewall on Windows Server 2008 helps prevent unauthorized access to computer resources. However, if the firewall is configured incorrectly, attempts to connect to an instance ofSQL Server may be blocked.To access an instance of SQL Server that is behind the firewall, you must configure the firewall on the computer that is running SQL Server.
This article helps you open the firewall ports for SQL Server on Windows Server 2008.
To have us fix this problem for you, go to the “Fix it for me”section. If you prefer to fix this problem yourself, go to the “Let me fix it myself” section.

Resolution
To fix this problem automatically, click theFix this problemlink. ClickRunin the File Downloaddialog box, and then follow the steps in this wizard.

a.button {background: url(/library/images/support/KBGraphics/PUBLIC/cn/FixItButton.jpg) no-repeat 0 0;width: 139px;height: 56px;display:block;cursor:pointer;}a.button:hover {background-position: bottom right;}Fix this problem
Microsoft Fix it 50169

Note this wizard may be in English only; however, the automatic fix also works for other language versions of Windows.
Note if you are not on the computer that has the problem, save the Fix it solution to a flash drive or a CD and then run it on the computer that has the problem.
Next, go to the “Did this fix the problem?” section.

A delimited flat file is parsed incorrectly when you use the Flat File source or a Flat File connection manager in SQL Server 2008

Symptoms
In Microsoft SQL Server 2008, when you use the Flat File source to enable a package to read data from a text file, or you use the Flat File connection manager to enable a package to extract and load data from a flat file, some rows are parsed incorrectly. Additionally, data may beattributed to the wrong columns in some rows.
This problem occurs for one of the following reasons:The flat file contains comma-separated values (CSV).The flat file contains a different delimiterthat contains a variable number of columns.
Resolution
This problem occurs because the Flat File source and the Flat File connection manager in SQL Server 2008 Integrated Services (SSIS) do not support “Ragged right format” reading of delimited flat files if the files contain a different number of delimiters in the rows.
Note This problem may cause the parser to read ahead and fill the rest of the row with values from the next row.