D
Darin
I have a stored procedure with 15 arguments that, when run using Query
Analyzer takes 2.5 minutes to run. In my VB.NET code, when I go to run
the same SP with the same parameters, I get a timeout message after 15
minutes.
Why would VB take 5 times longer to run the same SP?
Below is how I run it in VB:
strcommand=new sqlcommand(in_sp, xconn)
strcommand.commandtype=commandtype.storedprocedure
for each xpar in in_param
xparam=new sqlparameter(xpar.setname, xpar.setvalue)
strcommand.parameters.add(xparam)
next
strcommand.timeout=900 '15 minutes
strcommand.executescalar
In_Param is my own class that has the parameter name and value in it.
TIA
Darin
Analyzer takes 2.5 minutes to run. In my VB.NET code, when I go to run
the same SP with the same parameters, I get a timeout message after 15
minutes.
Why would VB take 5 times longer to run the same SP?
Below is how I run it in VB:
strcommand=new sqlcommand(in_sp, xconn)
strcommand.commandtype=commandtype.storedprocedure
for each xpar in in_param
xparam=new sqlparameter(xpar.setname, xpar.setvalue)
strcommand.parameters.add(xparam)
next
strcommand.timeout=900 '15 minutes
strcommand.executescalar
In_Param is my own class that has the parameter name and value in it.
TIA
Darin