How to tell which stored procedures are executing with params on SQL Azure

admin

Administrator
Staff member
I have moved my website to SQL Azure and Azure Websites. I have a performance issue with certain stored procedures which are timing out from the UI. I need to capture the <strong>exact</strong> SQL call with parameters and execute this in a query window to diagnose the issue.

When running SQL locally I would just run SQL Profiler and capture the SQL traffic. In SQL Azure I cannot do this.

I have tried the following unsuccessfully:

<ol>
<li>Running queries for DMV:

<a href="http://www.developer.com/services/how-to-identify-performance-bottlenecks-on-azure-sql-database.html" rel="nofollow">http://www.developer.com/services/how-to-identify-performance-bottlenecks-on-azure-sql-database.html</a>
<a href="http://programming4.us/database/2716.aspx" rel="nofollow">http://programming4.us/database/2716.aspx</a>
<a href="http://sqlserverperformance.wordpre...e-dmv-queries-that-will-make-you-a-superhero/" rel="nofollow">http://sqlserverperformance.wordpre...e-dmv-queries-that-will-make-you-a-superhero/</a>

(This showed me the worst performing queries, but NOT the exact stored proc call when I hit the frontend)</li>
</ol>

2 Installed Glimpse and checking the SQL tab (I am running a DotNetNuke site and the code does not use the correct interface, so this did not show the SQL Server stored procedures being executed)

<ol start="3">
<li>Fiddler (no SQL information in the HTTP call of course)</li>
<li>Azure "Manage Database" - this shows the slowest queries and is really useful, but NOT the currently incoming stored procedures
<a href="http://blogs.msdn.com/b/benko/archi...o-i-get-sql-profiler-info-from-sql-azure.aspx" rel="nofollow">http://blogs.msdn.com/b/benko/archi...o-i-get-sql-profiler-info-from-sql-azure.aspx</a></li>
</ol>

My last resort is to copy the whole site and database locally and set it up, but it seems like such a simple requirement...