3

We have two SQL Servers and have them set up as linked servers. There is one particular stored procedure that when run has to join tables from the linked server to it's own. Often times it seems to take forever and after looking a bit, it seems that in activity monitor it gets a "PREEMPTIVE_OLEDBOPS". But this is only when the SP is called from ASP.NET. When I run the query in SQL Server Management Studio the query runs in 6 seconds - everytime.

I am not a dba - so my knowledge here is pretty superficial. Googling for this error code, suggests it's a wait code, but I couldn't get any information about how to avoid them or what exactly is causing it.

Thanks for any help, ~P

Prescott
  • 7,312
  • 5
  • 49
  • 70
  • I'd sure love to see an answer to this one... I've got a "CREATE PROCEDURE" script running now for over an hour on a completely idle SQL server with a PREEMPTIVE_OLEDBOPS wait code. – NTDLS Mar 09 '11 at 04:28

1 Answers1

0

Try adapting your sp to use OPENQUERY command.

Nikhil S
  • 1,179
  • 1
  • 9
  • 19