Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

SQL Azure Profiling

I read on the MS site that SQL Azure does not support SQL Profiler. What are people using to profile queries running on this platform?

like image 248
CodeGrue Avatar asked Dec 18 '09 17:12

CodeGrue


People also ask

Does SQL Profiler work with Azure SQL?

The answer is 'Yes'. Make sure that you select the correct Azure SQL Database when you provide the Azure server details in the 'Connection' option as shown. You will get this 'Connection' option after you click on 'Launch Profiler' in the 'Command Palette' which was shown in the earlier sections.

What is SQL profiling?

Microsoft SQL Server Profiler is a graphical user interface to SQL Trace for monitoring an instance of the Database Engine or Analysis Services. You can capture and save data about each event to a file or table to analyze later.


3 Answers

I haven't got too far playing around with SQL Azure as yet, but from what I understand there isn't anything you can use at the moment.

From MS (probably the article you read):

Because SQL Azure performs the physical administration, any statements and options that attempt to directly manipulate physical resources will be blocked, such as Resource Governor, file group references, and some physical server DDL statements. It is also not possible to set server options and SQL trace flags or use the SQL Server Profiler or the Database Tuning Advisor utilities.

If there were to be an alernative, I'd imagine it would require the ability to set trace flags which you can't do, hence I don't think there is an option at the moment.

Solution? I can only suggest you have a local development copy of the db so you can run profiler locally on it. I know that won't help with "live" issues/debugging/monitoring but it depends on what you need it for.

Edit: Quote from MSDN forum:

Q: Is SQL Profiler supported in SQL Azure?

A: We do not support SQL Profiler in v1 of SQL Azure.

Now, you could interpret that as a hint that Profiler will be supported in future versions. I think it will be a big requirement to get a lot of people on board, using SQL Azure seriously.

like image 85
AdaTheDev Avatar answered Oct 16 '22 09:10

AdaTheDev


Update as of 9/17/2015:

Microsoft just announced a new feature called Index Advisor:

How does Index Advisor work? Index Advisor continuously monitors your database workload, performs the analysis and recommends new indexes that can further improve the DB performance.

Recommendations are always kept up-to-date: As the DB workload and schema evolves, Index Advisor will monitor the changes and adjust the recommendations accordingly. Each recommendation comes with the estimated impact to DB workload performance: You can use this information to prioritize the most impactful recommendations first. In addition, Index Advisor provides a very easy and powerful way of creating the recommended indexes.

Creating new indexes only takes a couple of clicks. Index Advisor measures the impact of newly created indexes and provides a report on index impact to users. You can get started with Index Advisor and improve your database performance with the following simple steps. It literally takes five minutes to get accustomed with Index Advisor’s simple and intuitive user interface. Let’s get started!

Original Answer:

SQL Azure now has some native profiling. See http://blogs.msdn.com/b/benko/archive/2012/05/19/cloudtip-14-how-do-i-get-sql-profiler-info-from-sql-azure.aspx for details.

like image 18
David Peden Avatar answered Oct 16 '22 10:10

David Peden


Microsoft's stated position SQL Server Profiler is deprecated. As much as this is a bad idea, that's what they have said.

SQL Profile is already deprecated in SQL Server, and that’s part of the reason that it doesn’t make sense to bring to SQL DB.

What this means is you are going back 20+ years in database performance monitoring and everyone is going to have to write their own perf monitoring scripts instead of having a standard factory delivered tool that's on every server you will go to. It's tantamount to deprecating "sp_help" and making every DBA write their own. Hope you know all your DMVs inside and out... INNER JOIN, OUTER JOIN, and CROSS APPLY syntax really well.

like image 5
frankmcb Avatar answered Oct 16 '22 08:10

frankmcb