Wrox Programmer Forums
|
SQL Server DTS Discussion specific to Data Transformation Service with SQL Server. General SQL Server discussions should use the general SQL Server forum. Readers of the book Professional SQL Server 2000 DTS with questions specific to that book should post in that book forum.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the SQL Server DTS section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old August 6th, 2004, 11:25 AM
Registered User
 
Join Date: Aug 2004
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default How to input ID ?

Hello.

I'm working in DTS from a couple of days. I have a data without an ID column and i'm importing it with DTS but want to add an ID column. I set this column with 'uniqueidentifier' type and mark a "Enable identiti insert" in Transform Data Task properties but don't work. It says that can't insert NULL into ID column...

How do this ?

 
Old August 6th, 2004, 11:43 AM
Registered User
 
Join Date: Aug 2004
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Sorry, but i just figure it out.

I change type of ID at int and add a 'counter' variable... so simple ;)

 
Old August 6th, 2004, 11:45 AM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 1,998
Thanks: 0
Thanked 3 Times in 3 Posts
Default

Hey,

A uniqueidentifier is different. The field is actually a GUID, and you got to use the NewID() to create a new guid for the row. If you want identity insertion, use an integer type (int, bigint) or numeric (numeric and decimal can specify a custom length).

Brian





Similar Threads
Thread Thread Starter Forum Replies Last Post
'this.ID = id;' in class construction holf BOOK: ASP.NET 2.0 Website Programming Problem Design Solution ISBN: 978-0-7645-8464-0 0 October 6th, 2006 10:58 AM
ID crmpicco HTML Code Clinic 5 February 10th, 2005 11:50 AM
more than 2 records with the same ID crmpicco Classic ASP Databases 7 January 27th, 2005 07:35 AM
why not index.asp?id=1 can be www.myweb.com/?id=1 BurhanKhan Classic ASP Professional 11 September 6th, 2004 02:06 PM
Record ID sinner Classic ASP Databases 12 February 28th, 2004 03:36 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.