Tables updated even though there is an error 80040e14

  • All,

    We are using a process that updates tables in SQL Server 2000. The process

    gives the following error but the table is updated even though there is an error.

    My question is why are the tables still updated? The process does not retry the update. Does anyone know if this is a bug in SQL Server? The process is trying to commit 2 update statements.

    Thanks,

    *** Scripting Step Begin: [Set Process Stage Success_4]

    06/20/2007 15:02:16 4 0 O Global Update Opportunity set Last_Export_Date = '6/20/2007 15:01:55', External_Last_Update = '6/20/2007 15:01:55', External_Source_Sync_Status = 'Cancel Sync''d', TOC_Last_Export_Pipeline = 'Contract' Where Opportunity_Id = 0x00000000000004ec

    Update Int_PVTL_Stg_Contract set Processed = 'S',Processed_Date = '6/20/2007 15:01:55' Where Int_PVTL_Stg_Contract_Id = 0x0000000000000147

    06/20/2007 15:02:16 1 0 O Global *** Scripting Step End: [Set Process Stage Success_4] completed.

    06/20/2007 15:02:16 1 0 O Global *** SQL Session Started: [PVTL]

    06/20/2007 15:02:16 1 0 O Global *** SQL Step Begin: [Update Stage_2]

    06/20/2007 15:02:16 4 54 O Global ExecuteSQLCommand(MaxDataLength=104857...): HResult of -2147217900 (80040e14) Error Source: Microsoft OLE DB Provider for SQL Server

    Error Description : Line 1: Incorrect syntax near '='.

    06/20/2007 15:02:16 1 -2147217900 O Global *** SQL Step End: [Update Stage_2] failed.

    06/20/2007 15:02:16 1 0 O Global *** SQL Session Ended: [PVTL]

  • It would have happened if you are not using transaction and the database is set to auto commit mode.

    Cheers,
    Sugeshkumar Rajendran
    SQL Server MVP
    http://sugeshkr.blogspot.com

  • are you sure they are all wrapped in a transaction?

    if you are simply running 4 statements, ie 4 updates,a nd the 3rd crashed, the first two might already be committed unless you are wrapping all 4 in a transAactipn;

    ie:

    set xact_abort on --if any error, rollback all transactions for this session:

    begin tran

    update ...

    update ...

    update ...

    commit tran

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic. Login to reply