You could send the whole dataset ( from step 1) to a storedprocedure as
XML, and let that sp take care of it.
The sp can update existing records, add new records and delete
unnecessary records (propably without a cursor).
************************************************** **************
Tapio Kulmala
"Those are my principles. If you don't like them I have others."
- Groucho Marx
************************************************** **************
In article <O4y3m6s9FHA.1140@tk2msftngp13.phx.gbl>,
Jeff@NoSpam.com
says...[color=blue]
>
> The following strategy did not work (but shows the sort of thing I'd like to
> be able to do):
> 1. Create/populate DataSet from Excel data (then validate it)
> 2. Retrieve DataSet populated from SQL db table
> 3. .Merge() the two DataSets
> 4. Identify all the rows, and only the rows, that are different - per
> DataSet.GetChanges()
> 5. Send all the changes and only the changes to the database via a
> DataAdapter's command objects (e.g., InsertCommand, UpdateCommand,
> DeleteCommand) - each of which would call a stored procedure and pass it
> parameters to do the actual update.
>[/color]
--