I got a dts package to move data from one server to another. It ends up in a results table. I am tryin gto truncate a 4 field table and then repopulate it from this results table (same 4 fields) Seems easy but for some reason it is beyond me LOL.
Can someone please tell me what the syntax should be after truncating the table that is to get the information. Or should I drop it and do insert into

MOVING DATA BETWEEN SERVERS
Scripto
Well, if you're simply moving the data from the results table to the truncated table, for best performance I'd simply drop the truncated table your talking about, then have the DTS package push data into a new table named the same as the dropped table.
If you need to import into a staging table first, for filtering/scrubbing/etc., your next best performing option would be to drop the table instead of truncating, then performing a bulk operation using select...into:
select <columns> into <dropped table name> from <results table> where <filters>
If you can't do that, guess you're stuck using a straight insert statement:
insert <truncated table name> (<columns>) select <columns> from <results table>
HTH
JulienH
(
Col1,
Col2,
Col3,
Col4
)
SELECT
Col1,
Col2,
Col3,
Col4
From ResultsTable
Did you mean this
HTH, Jens Suessmeyer.
---
http://www.sqlserver2005.de
---