Theory/advice question, without making you have to read a long explanation. I need to process a lot of data from a lot of tables. About 1070 tables, 120 million records, not normalized.... />
So I can't change any of the source issues, but I need to get data out.... single complex SQL is overtaxing the server so I was thinking about eating the elephant one bite at a time and tiering my SQL... But I am not sure this is any better or faster then a Complex SQL.
Dim userparam as string Dim SQL1 as string Dim SQL2 as string dim SQl3 as string dim SQl4 as string ' all the other data connection code sql1 = "Select * from firsttable where firstfield =" + SQL1 ' throw it in a datagrid and cycle with a FOR statement ' use the reference key to query the next table Secondcriteria = "reference key from first datagrid" For i = 0 to count of datagrid SQl2 = "select * from secondtable where Secondfield =" + Secondcriteria(i) 'Rinse repeat FOR statements and datagrids till I get the final Dataset
I am hoping someone has experience with this problem and can give me some advice or references about the issue. Thank you for your time.