Any reason why parametrized SQL code would be slower than a stored procedure? I mean, unless your statement is so big that the network overhead of sending it would be significant, a parametrized statement would have its execution plan cached by the server, same as the stored procedure. Of course it's a lot more interesting to get all the results you need in one statement instead of looping over every row and issuing a SQL statement for every row. Same goes for LDAP.
C
Christophe Van Olmen
@Christophe Van Olmen
Posts
-
Does anybody really use a Profiler? -
performance or accuracy?Probably something you already considered but which can have an enormous impact in loading your data: transactions. Grouping as much data together before committing can increase loading performance to a factor 100 (as usual, experiment with size of transaction for best result in your situation). Timing of the process is also extremely important: you might experience slow performance due to locking issues. To me, accuracy seems the most important criterium (inaccurate = wrong).