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 Administration (2000)
 Loading records

Author  Topic 

itmasterw
Yak Posting Veteran

90 Posts

Posted - 2007-12-11 : 10:41:01
We have a DTS package that runs every day. On a daily basis it pulls records from a text file and loads them into a temp table. It then does a minor check for something and if the at something is there updates a history table. Anyway, it moves the records to a main transaction table; and that is it. However, while it is always successful in moving the data to the temp table, every so often it will drop a record, when loading the transaction table. we have checked the file there is nothing wrong with the data and the DTS pack age works fine. When I run DBCCSHOWCONTIG I get a scan Density of 99.8% showing a little fragmentation, but I do not thing this would cause this? Is there anything else I can check?
I do not know, but any ideas I would really appreciate.
Thank You


ITM

harsh_athalye
Master Smack Fu Yak Hacker

5581 Posts

Posted - 2007-12-11 : 10:46:39
Why don't you use staging table instead of temp table?

Harsh Athalye
India.
"The IMPOSSIBLE is often UNTRIED"
Go to Top of Page

RickD
Slow But Sure Yak Herding Master

3608 Posts

Posted - 2007-12-11 : 11:03:09
Where will it drop the record from? The temp table or the tranasaction table?

Are you using transactions when performing the last step?
Go to Top of Page

itmasterw
Yak Posting Veteran

90 Posts

Posted - 2007-12-11 : 13:06:13
Please for give me if I am not explaining this right. But when I say a temp table I mean it loads to an actual table not a virtual table; so I guss that might be your staging table. And it drops it from the move from the temp to the main table. And not we are not at that poit usint the transactions. It runs at night and no one would be in there. However, I will check if there is other jobs that runing at the same time. Could that cause a droped record?


ITM
Go to Top of Page

itmasterw
Yak Posting Veteran

90 Posts

Posted - 2007-12-11 : 13:38:19
Also, I checked there is nothing runing at the time in the morning when this is ran and nothing touches(or uses the rcords) in the transaction table.

ITM
Go to Top of Page

rmiao
Master Smack Fu Yak Hacker

7266 Posts

Posted - 2007-12-11 : 23:02:51
Trace it with profiler.
Go to Top of Page

harsh_athalye
Master Smack Fu Yak Hacker

5581 Posts

Posted - 2007-12-12 : 02:04:47
Is it physical temp table? Or you create it on the fly and drop it later?

Harsh Athalye
India.
"The IMPOSSIBLE is often UNTRIED"
Go to Top of Page

itmasterw
Yak Posting Veteran

90 Posts

Posted - 2007-12-12 : 07:54:10
It is a table that the DTS process creates and then drops; but it isn't vertual table, like the ones you would use as say #tran. This just creats a table and then drops it.

Harsh Athalye
India.
"The IMPOSSIBLE is often UNTRIED"
[/quote]

ITM
Go to Top of Page
   

- Advertisement -