locked
copy database wizard - error message RRS feed

  • Question

  • I'm trying to use the "copy database wizard" but am getting a strange error message I cannot decipher;

      Event Name: OnError
     Message: An exception occurred while executing a Transact-SQL statement or batch.
    StackTrace:    at Microsoft.SqlServer.Management.Common.ServerConnection.ExecuteNonQuery(String sqlCommand, ExecutionTypes executionType)
       at Microsoft.SqlServer.Management.Common.ServerConnection.ExecuteNonQuery(StringCollection sqlCommands, ExecutionTypes executionType)
       at Microsoft.SqlServer.Management.Common.ServerConnection.ExecuteNonQuery(StringCollection sqlCommands)
       at Microsoft.SqlServer.Dts.Tasks.TransferObjectsTask.TransferObjectsTask.CreateObject(String database, StringCollection script)
       at Microsoft.SqlServer.Dts.Tasks.TransferObjectsTask.TransferObjectsTask.TransferJobs(DatabaseObject dbObject)
    InnerException-->Cannot insert the value NULL into column 'owner_sid', table 'msdb.dbo.sysjobs'; column does not allow nulls. INSERT fails.
    The statement has been terminated.
    StackTrace:    at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection)
       at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection)
       at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj)
       at System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj)
       at System.Data.SqlClient.SqlCommand.RunExecuteNonQueryTds(String methodName, Boolean async)
       at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult result, String methodName, Boolean sendToPipe)
       at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
       at Microsoft.SqlServer.Management.Common.ServerConnection.ExecuteNonQuery(String sqlCommand, ExecutionTypes executionType)
     Operator: NT AUTHORITY\SYSTEM
     Source Name: CDW_TA_LIVE_2
     Source ID: {EF45B426-C146-4C7D-8027-3F8368D3BB11}
     Execution ID: {0D6468A6-5C30-4601-9C4B-6D6870DD847B}
     Start Time: 9/26/2008 5:18:58 PM
     End Time: 9/26/2008 5:18:58 PM
     Data Code: 0


    I am copying from one SQL 2005 server to another SQL 2005 server on the same network and have all authorities.


    Thursday, September 25, 2008 10:32 PM

Answers

  • In the source database, your sysjobs table has a null value for the owner_sid column in one of the rows. The destination database doesn't allow nulls in that column, so the transfer is failing.

     

    Not sure how you ended up with a nullable column there, though.

    Friday, September 26, 2008 1:50 PM

All replies

  • In the source database, your sysjobs table has a null value for the owner_sid column in one of the rows. The destination database doesn't allow nulls in that column, so the transfer is failing.

     

    Not sure how you ended up with a nullable column there, though.

    Friday, September 26, 2008 1:50 PM
  • The only option I had was to allow nulls. I can't open the table to see what row might have a null entry (even though null entries are not allowed). So, I did that and tried the copy again. I get the following error that I do not understand;

     Event Name: OnError
     Message: The network path was not found.

    StackTrace:    at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
       at System.IO.File.InternalCopy(String sourceFileName, String destFileName, Boolean overwrite)
       at Microsoft.SqlServer.Dts.Tasks.TransferObjectsTask.TransferObjectsTask.CopyFile(String sourceFileName, String destinationFileName, Boolean overwriteOnExist)
     Operator: NT AUTHORITY\SYSTEM
     Source Name: 10_10_31_194_LIVE_Transfer Objects Task
     Source ID: {DE44D228-863F-4E41-BABE-F730EBE00EAA}
     Execution ID: {DE1CDC17-8C7C-44A6-B663-81C85125CE09}
     Start Time: 9/27/2008 9:37:24 AM
     End Time: 9/27/2008 9:37:24 AM
     Data Code: 0

    For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.

    I'm guessing that I don't have something defined like a share to 10.10.31.194.

    Friday, September 26, 2008 3:22 PM