Here I am dealing with a database containing tens of millions of records. I have an application which connects to the database, gets all the data from a single column in a table and does some operation on it and updates it(for mssql - using cursors).
For millions of records it is taking very very ... long time to update.So I want to make it faster by i).using multiple threads with an independent connection for each thread. or ii).by using a single connection throughout all the threads to fire the update queries.
Which one is faster, or if you have any other ideas plz explain.
I need a solution which is independent of database type , or even if you know specific solutions for each type of db, plz reply.