dbTalk Databases Forums  

"Attempt to insert null data" error

microsoft.public.sqlserver.dts microsoft.public.sqlserver.dts


Discuss "Attempt to insert null data" error in the microsoft.public.sqlserver.dts forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
et
 
Posts: n/a

Default "Attempt to insert null data" error - 06-27-2005 , 03:19 PM






I have a table with 2 columns that I am copying into 3, with the 3rd column
being an identity column, and I have the Enable identity insert checked,
with an "ignore" selected under the transformation columns. But I keep
getting the error that it can't insert data because the ID field cannot be
null. How do I copy a table from one database to another and have it
populate the identity field at the same time?



Reply With Quote
  #2  
Old   
Allan Mitchell
 
Posts: n/a

Default Re: "Attempt to insert null data" error - 06-27-2005 , 03:24 PM






Have you seen this article?

Problems With IDENTITY() and the DataPump task.
(http://www.sqldts.com/default.aspx?293)

--



Allan Mitchell MCSE,MCDBA, (Microsoft SQL Server MVP)
www.SQLDTS.com - The site for all your DTS needs.
www.SQLIS.com - You thought DTS was good. here we show you the new stuff.
www.konesans.com - Consultancy from the people who know


"et" <eagletender2001 (AT) yahoo (DOT) com> wrote

Quote:
I have a table with 2 columns that I am copying into 3, with the 3rd column
being an identity column, and I have the Enable identity insert checked,
with an "ignore" selected under the transformation columns. But I keep
getting the error that it can't insert data because the ID field cannot be
null. How do I copy a table from one database to another and have it
populate the identity field at the same time?




Reply With Quote
  #3  
Old   
et
 
Posts: n/a

Default Re: "Attempt to insert null data" error - 06-27-2005 , 05:20 PM



Thanks so much, it hit the nail on the head. I thought I had tried just
about every scenario there was, but this did the trick, so Thanks!

"Allan Mitchell" <allan (AT) no-spam (DOT) sqldts.com> wrote

Quote:
Have you seen this article?

Problems With IDENTITY() and the DataPump task.
(http://www.sqldts.com/default.aspx?293)

--



Allan Mitchell MCSE,MCDBA, (Microsoft SQL Server MVP)
www.SQLDTS.com - The site for all your DTS needs.
www.SQLIS.com - You thought DTS was good. here we show you the new stuff.
www.konesans.com - Consultancy from the people who know


"et" <eagletender2001 (AT) yahoo (DOT) com> wrote in message
news:uWKMDW1eFHA.3028 (AT) TK2MSFTNGP09 (DOT) phx.gbl...
I have a table with 2 columns that I am copying into 3, with the 3rd
column being an identity column, and I have the Enable identity insert
checked, with an "ignore" selected under the transformation columns. But
I keep getting the error that it can't insert data because the ID field
cannot be null. How do I copy a table from one database to another and
have it populate the identity field at the same time?






Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.