none
cannot insert into a row version column

    Question

  • I am getting an error during export/import. My source and destination tables has "timestamp" datatype column.

    Create table SourceTable (

    Rowid  numeric(10,0) identity,

    Row_version  timestamp null

    )

    create table DestTable (

    Rowid   Numeric(10,0) identity,

    Row_version   timestamp  NULL

    )

    I get the following error:

    Error 0xc0202048: Data Flow Task: Attempting insertion into the row version column "row_version". Cannot insert into a row version column.
    (SQL Server Import and Export Wizard)

    Thanks in advance

    mjrp

     

    Wednesday, December 13, 2006 9:23 PM

All replies

  • Well, "rowversion" is a reserved word.  Do you perhaps have an error somewhere?  Or is the Import/Export Wizard treating row_version as the same as "rowversion"?
    Wednesday, December 13, 2006 9:56 PM
  • I changed the column name to xyz, but still getting the same error message.  Please be aware that the data type is "timestamp".  The table is in SQLserver 2005 database and using export/import wizard in sql server 2005.

    Thanks

     

     

    Wednesday, December 13, 2006 10:34 PM
  • I tested the above scenario in BIDS 2008 against SQL Server 2005 Sp2. I was able to create an SSIS package using Import/Export wizard and excuted the package without any error message. I found my data has been copied too.

    Table def (being same for source and dest.)

    USE

     

    [Test]

    GO

    /****** Object: Table [dbo].[DestTable] Script Date: 04/20/2009 12:42:51 ******/

    SET

     

    ANSI_NULLS ON

    GO

    SET

     

    QUOTED_IDENTIFIER ON

    GO

    CREATE

     

    TABLE [dbo].[DestTable](

    [Rowid] [numeric]

    (10, 0) IDENTITY(1,1) NOT NULL,

    [Row_version] [timestamp]

    NULL

    )

     

    ON [PRIMARY]

    How did you use the export/import wizard? as the name is spelled out as Row_version, I would not think it would conflict with the reserve word "rowversion"

    Monday, April 20, 2009 5:56 PM