Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 re: Updating records with same primary key

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2001-04-30 : 11:14:28
Chris writes "I have two databases, DatabaseA and DatabaseB. DatabaseA is used to load data that I receive daily from an application service provider. The data contains company timecards. The timecard table (t_timecard) contains records that have the same primary key. This happens because whenever an employee edits a time entry, another instance of the record is created (same primary key but some entries may have changed i.e. - hours worked). I have timestamps on the records so I can compare timestamps to determine which record to keep. I also need to move the record that is being replaced to a table of it's own so accounting can run an exception report. This has me a bit stumped? Any ideas, Gurus?

Thanks,
Chris"
   

- Advertisement -