0

I am calling a SQL Server stored procedure from Entity Framework like this:

datacontext.INITIAL_CHECK(FileKey);

My connection string has connection time out defined as 600 seconds.

But the stored procedure execution is aborting with an "Execution timeout expired" exception.

When I run the same stored procedure through SQL Server Management Studio, it finishes in 43 seconds.

marc_s
  • 732,580
  • 175
  • 1,330
  • 1,459
Sachu
  • 7,555
  • 7
  • 55
  • 94
  • The timeout in the connection string is just for this : for **connecting** to the database. It has absolutely **NOTHING** to do with the **command timeout** - how long a command can run before a timeout occurs .... – marc_s Nov 21 '22 at 05:11
  • @marc_s can you help me hw to set the command timeout in data context with linq? – Sachu Nov 21 '22 at 05:14
  • Just **search** this site - https://stackoverflow.com/search?q=set+command+timeout+in+entity+framework - there are already ***TONS*** of responses..... – marc_s Nov 21 '22 at 05:15

0 Answers0