Wrox Programmer Forums
Go Back   Wrox Programmer Forums > SQL Server > SQL Server DTS
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 March 8th, 2005, 01:52 PM
Registered User
Join Date: Mar 2005
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default Creating a Unique ID for each row

I'm new to DTS and SQL Server, so I appoligize if this is an easy question. I have to query several tables and export the data to an external DB. I need to create a unique ID for each row that is selected from each table. This ID can simply be a row counter. So, if I count 2000 rows from the first table and output them to the external DB file, then the second query needs to start with ID#2001 for its counting. I'd guess that I could query the external DB file to find the max value and pass it to the second step, but don't know how to do that either. Thanks

Max A. Worlund
CDC Information Technology Support Contract (CITS)
Software Engineer III
email:  zqy3@cdc.gov
Old March 8th, 2005, 09:33 PM
Registered User
Join Date: Feb 2005
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts

if the external DB to which you are trying to export is an SQL DB then you can make the unique ID column as an identity column.

good day

Similar Threads
Thread Thread Starter Forum Replies Last Post
generate unique id capri SQL Server 2000 1 April 6th, 2008 10:18 AM
Create Unique Id langer123 Classic ASP Basics 0 April 6th, 2005 01:27 PM
Merging 2 documents, joining on a unique ID remote XSLT 1 March 8th, 2005 03:23 PM
Getting Unique ID from Database Nicky_uk Classic ASP Databases 9 January 26th, 2005 04:45 PM
Generate unique ID when populating a table sroman SQL Server 2000 2 August 5th, 2003 03:38 AM

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