Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
victorsarathy
Starting Member
8 Posts |
Posted - 2008-08-07 : 21:01:13
|
| Dear friends, Here I am new for. Greeting to all. Now,I am using SQL SERVER . I attained Timeout problem when insert record.Application server is C++/CLI, SQL connection time out is 60 secs.Please note my statement as follows and reply ASAP.Sample statement. INSERT INTO TABLE_NAME(X,Y) SELECT X,Y FROM TABLE_SOURCEThe TABLE_SOURCE have 10000 rows.Any SQLSERVER reply ASAP.Thanks |
|
|
TG
Master Smack Fu Yak Hacker
6065 Posts |
Posted - 2008-08-07 : 23:00:04
|
| If you issue this insert statement in a query window (not from your application) how long does it take? When you are experiencing this problem, run this statement in a query window to see if there is any blocking processes:exec sp_who2 activeSee if there are any values in the blkby column. If so they are SPIDs from other sessions. you can use this statement to see what command the blocking SPID is:dbcc inputbuffer(<SPID>)Other possible factors:Are there foreign key constraints, check constraints, or many indexes on the target table?Be One with the OptimizerTG |
 |
|
|
rmiao
Master Smack Fu Yak Hacker
7266 Posts |
Posted - 2008-08-07 : 23:01:31
|
| Any connection problem? Did you see blocking on sql server? |
 |
|
|
victorsarathy
Starting Member
8 Posts |
Posted - 2008-08-08 : 01:12:30
|
quote: Originally posted by TG If you issue this insert statement in a query window (not from your application) how long does it take? When you are experiencing this problem, run this statement in a query window to see if there is any blocking processes:exec sp_who2 activeSee if there are any values in the blkby column. If so they are SPIDs from other sessions. you can use this statement to see what command the blocking SPID is:dbcc inputbuffer(<SPID>)Other possible factors:Are there foreign key constraints, check constraints, or many indexes on the target table?Be One with the OptimizerTG
Dear TG, Thanks for you reply. >If you issue this insert statement in a query window (not from your application) how long does it take? it takes 50 sec > When you are experiencing this problem, run this statement in a query window to see if there is any blocking processes:exec sp_who2 active There are no blocking processing >Other possible factors: Are there foreign key constraints, check constraints, or many indexes on the target table? There is no more foreign key constraints, check constraints and more indexes . I have done the followings things.. 1. In client application:- C#.NET service.Timeout = System.Threading.Timeout.Infinite; 2. In IIS server property :- Default 900 3. In server application:- C++/CLI ASP.NET Webservice sqlop->SqlCmd->CommandTimeout = 0; 4. Set infinity (0) in SQL server enterprice server connection Timeout propery. I have done the above things. Even I got timeout exception in client applicaiton. And one more thing..Please can you do favour for me. I have done DLL for data base access. When I retirce more data like above 1000 rows, it will talk some time. It is very slow to fetch record. I dont know where is the problem. Problem in datafetch or datareader?. And there is no more exception in data fetch. So please reply how can get more records from SQL server.ThanksSarathy |
 |
|
|
TG
Master Smack Fu Yak Hacker
6065 Posts |
Posted - 2008-08-08 : 09:02:28
|
| What are the datatypes of the target table? Are there large datatypes ie: text, ntext, image, nvarchar(max), etc? 10,000 rows is a lot of operations for a frontend to wait on.Be One with the OptimizerTG |
 |
|
|
|
|
|
|
|