Dataset Fill Desktop vs WEB

I have an sql server command, calling a stored procedure. actually the problem happens with all types of commands but this is my test only.

1- i have tested calling the procedure from inside SQL server management studio, it took 34 Seconds to execute.

2- i have created a desktop application using SQLConnection and called the same procedure with same parameters, it took 36 seconds to execute.

3- I have created a web application and used exactly the same code i used in the desktop one, and called the same procedure with same parameters and it takes 01:38 Second to execute, means almost more than one minutes delay for calling the same code from web application, with same System.Data.SqlClient with a DataAdapter and fill command to a DataSet.

i made a big research over internet, all companies are trying to make a mall answer related to the programmer case and just asking for more about details about the command, but if the same command takes deferent time with deferent calls using same dlls, then the problem is in the technology, and mostly in the sql connection policy.

Please what sql connection string i need to use to exactly simulate sql server management studio connection for Sql server that exists in the same PC.

Noting that i have made many tries to connect using various network libraries, but same results happened. and same problem happens with Sql 2005,2008,2012,2014

Thanks and best regards...

1 answer

Post your code and show us what you are doing.

How fast is your connection and the web server?