Hi all, ok I have this problem where I need to process 50,000+ records from three different tables on two different servers thus 150,000+ records. Now I have got this program to work, however, it runs two slow. I do the following:
Servers:
ServerA, Server B
Databases
ServerA.DB1, ServerB,DB2
Tables
DB1.TBL1, DB2.TBL1, DB2.TBL2
1) Get Row from DB1.TBL1, called CurRecord
2) Create a string from 4 records from said row, called RowID
3) find RowID in DB2.TBL1
4) Once Found get IDNumber from DB2.TBL1
5) Find IDNumber in DB2.TBL2
6) Once found get PageNumber
7) Comapre DB2.TBL2.PageNu mber to DB1.TBL1.PageNu mber, depending on result (i.e. = or <>) change a field in DB1.TBL1.CurRec ord
Repeat until all records in DB1.TBL1 have been processed
Now I have tried, Datasets, Hashtables, only SQL, datareaders, and any combination of them to try and achieve the fastest processing time. Everyone on the MSDN forums keep telling me to use SQLBulkCopy, but that is not my issue, it is processing the information. Oh I have also tried placing a Primary Key on the tables, as well as threading. My fastest time is 1 hour, I need to get it as close to 10 minutes as possible. I am running out of ideas, hence my posting this thread. Thus my question, if you have any ideas on what I can do in VB.Net to increase processing speed of such a problem i would be most greatful. I am looking for ideas for me to research/ try You don't have to give and I am not asking for a complete answer just a nudge in the right direction is all. Thank you for you help in advance!
Servers:
ServerA, Server B
Databases
ServerA.DB1, ServerB,DB2
Tables
DB1.TBL1, DB2.TBL1, DB2.TBL2
1) Get Row from DB1.TBL1, called CurRecord
2) Create a string from 4 records from said row, called RowID
3) find RowID in DB2.TBL1
4) Once Found get IDNumber from DB2.TBL1
5) Find IDNumber in DB2.TBL2
6) Once found get PageNumber
7) Comapre DB2.TBL2.PageNu mber to DB1.TBL1.PageNu mber, depending on result (i.e. = or <>) change a field in DB1.TBL1.CurRec ord
Repeat until all records in DB1.TBL1 have been processed
Now I have tried, Datasets, Hashtables, only SQL, datareaders, and any combination of them to try and achieve the fastest processing time. Everyone on the MSDN forums keep telling me to use SQLBulkCopy, but that is not my issue, it is processing the information. Oh I have also tried placing a Primary Key on the tables, as well as threading. My fastest time is 1 hour, I need to get it as close to 10 minutes as possible. I am running out of ideas, hence my posting this thread. Thus my question, if you have any ideas on what I can do in VB.Net to increase processing speed of such a problem i would be most greatful. I am looking for ideas for me to research/ try You don't have to give and I am not asking for a complete answer just a nudge in the right direction is all. Thank you for you help in advance!
Comment