BUG: Default of @@DBTS Causes Access Violation When Using BCPLast reviewed: May 1, 1997Article ID: Q136371 |
The information in this article applies to:
SYMPTOMSWhen you use use @@DBTS as a default bound to a column that is defined as varbinary (8), the server receives an access violation:
Msg 0, level 19, state 0: Server <server name>, line 1: language_exec: process 9 generated access violation; SQL Server is terminating this process Operating-system error: ConnectionWrite(WriteFile()). DB-LIBRARY error: possible network error: error in sending out-of-band data to SQL server Connection broken" when attempting to BCP data in. WORKAROUND
STATUSMicrosoft has confirmed this to be a problem in SQL Server versions 4.21a and 6.0. We are researching this problem and will post new information here in the Microsoft Knowledge Base as it becomes available.
MORE INFORMATIONThe following script causes a handled access violation in SQL Server version 6.0: 1)Set the database to pubs.
create table testbcp (dt binary (8), str1 char (10), str2 char (10)) go create default dtdef as @@DBTS go sp_bindefault dtdef, "testbcp.dt" go use master go sp_dboption pubs, "select into/bulkcopy", true go use pubs go checkpoint2) create a data file called c:\data.dat similar to:
row1col2,row1col3 row2col2,row2col3 and a format file called c:\data.fmt similar to the following: 6.0 3 1 SQLCHAR 0 0 "" 1 dummy 2 SQLCHAR 0 10 "," 2 str1 3 SQLCHAR 0 10 "\r\n" 3 str23) BCP the data in by going to a command prompt and typing:
bcp pubs..testbcp in c:\data.dat /f c:\format.fmt /Usa /PImmediately after executing the bcp command, the server receives an access violation.
|
Additional query words: SQL6 av
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |