> We are using the stored procedure to do a If Exist, update, else Insert > processing for > each record.
Consider loading the data in batches into a temporary table and then use a single insert statement to insert new records and a single update statement to update existing ones. This way, you are not forcing the database to do it one by one and give it a chance to aggressively optimize your queries and update the indexes in bulk. You'd be surprized at the difference this can make! -- http://mail.python.org/mailman/listinfo/python-list