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.

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 SQL Time out exeception

Author  Topic 

johnchristraj
Starting Member

3 Posts

Posted - 2009-08-27 : 05:33:05
HI
Am facing the problem while calling the SP.

My .Net applications calls the sp from the Front End (Code Behind), while calling the SP time out is happening after receving the exception I tried executing the same SP in back end and its executing properly.

After this I tried rename the SP and tried call from the same with .Net Application and its executes fine without timeout exeception.

Even I tried using alter procedure command without changing anything the query executed successfully from the application.

I struggling to fix this issues please help me to resolve the same.

Thanks in advance.

Cheers
John

ahmad.osama
Posting Yak Master

183 Posts

Posted - 2009-08-27 : 05:59:21
quote:
Originally posted by johnchristraj

HI
Am facing the problem while calling the SP.

My .Net applications calls the sp from the Front End (Code Behind), while calling the SP time out is happening after receving the exception I tried executing the same SP in back end and its executing properly.

After this I tried rename the SP and tried call from the same with .Net Application and its executes fine without timeout exeception.

Even I tried using alter procedure command without changing anything the query executed successfully from the application.

I struggling to fix this issues please help me to resolve the same.

Thanks in advance.

Cheers
John



create the sp with recompile option....
Go to Top of Page

ashishashish
Constraint Violating Yak Guru

408 Posts

Posted - 2009-08-27 : 06:14:11
quote:
Originally posted by ahmad.osama

quote:
Originally posted by johnchristraj

HI
Am facing the problem while calling the SP.

My .Net applications calls the sp from the Front End (Code Behind), while calling the SP time out is happening after receving the exception I tried executing the same SP in back end and its executing properly.

After this I tried rename the SP and tried call from the same with .Net Application and its executes fine without timeout exeception.

Even I tried using alter procedure command without changing anything the query executed successfully from the application.

I struggling to fix this issues please help me to resolve the same.

Thanks in advance.

Cheers
John



create the sp with recompile option....




Here is the use of recompile option for SQL Server Store Procedure from books online...

"RECOMPILE indicates that SQL Server does not cache a plan for this procedure and the procedure is recompiled at run time. Use the RECOMPILE option when using atypical or temporary values without overriding the execution plan cached in memory."

So i don't think that Recompile suites for this purpose. Its not an recompilation issue. you may check the time out settings for this or try to make time out to infinty with in your code.
Thanks.

iF theRe iS a wAy iN tHen theRe iS a wAy oUt..
Go to Top of Page

johnchristraj
Starting Member

3 Posts

Posted - 2009-08-27 : 06:34:23
I tried increse the timeout even though it cause with same problem
Go to Top of Page

johnchristraj
Starting Member

3 Posts

Posted - 2009-08-27 : 08:59:01
Can recompile cause any cause any performance issue?. Kndly suggest the solution for this issue

Thanks so much in advance

John
Go to Top of Page

russell
Pyro-ma-ni-yak

5072 Posts

Posted - 2009-08-27 : 09:09:32
let's see the proc. and tell us which fields are indexed, and when was last index rebuild
Go to Top of Page
   

- Advertisement -