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 |
|
saini_balvinder
Starting Member
22 Posts |
Posted - 2008-01-29 : 02:14:03
|
| i am using sql server 2000. and have a DTS with script in it. now the script if failing saying timeout expired. The script has db connection and calls stored procedure to fetch data. The records are around 63K but its failing due to timeout expired.is there a way to increase the timeout in script. i dont want to do any changes to sql server settings. |
|
|
saini_balvinder
Starting Member
22 Posts |
Posted - 2008-01-29 : 02:32:37
|
| i have set ConnectionTimeout = 0 in script. but still its failing with same timeout error.the code is as follows:Function Main() set conn = CreateObject("ADODB.Connection") conn.ConnectionTimeout=0 conn.open DTSGlobalVariables("DB_Conn").Value fromdate = DTSGlobalVariables("fromdate").Value todate = DTSGlobalVariables("todate").Value repairstatus = DTSGlobalVariables("repairstatus").Value RepairType = DTSGlobalVariables("RepairType").Value CarrierName = DTSGlobalVariables("CarrierName").Value Productcd = DTSGlobalVariables("Productcd").Value timefrom = DTSGlobalVariables("timefrom").Value timeto = DTSGlobalVariables("timeto").Value sql_exeSP= " EXEC SP_TBLFAULTMAIN_TEMP_DATA '"& repairstatus&"','"&fromdate&"','"&todate&"','" &RepairType&"','" &CarrierName&"','"&Productcd & "','" &timefrom&"','"&timeto&"' " conn.Execute(sql_exeSP) conn.Execute("EXEC SP_OTHERFILDS_TEMP") set conn = nothing Main = DTSTaskExecResult_SuccessEnd Function |
 |
|
|
saini_balvinder
Starting Member
22 Posts |
Posted - 2008-01-29 : 05:04:57
|
| In Enterprise Manager, under Database setting tab, the "Time out period" is set to "Wait indefinitely".any idea why still i get timeout error?Thanks |
 |
|
|
saini_balvinder
Starting Member
22 Posts |
Posted - 2008-01-29 : 23:34:41
|
| can anyone help on this? thx |
 |
|
|
saini_balvinder
Starting Member
22 Posts |
Posted - 2008-01-30 : 01:03:14
|
| well i found solution to this. In the script we need to set connectionName.CommandTimeout property to 0.earlier i was using,connectionName.connectiontimeout=0 which was not working.hope it helps if u need it. Thanks |
 |
|
|
|
|
|