How to use SQL Profiler in ADS

Susja 716 Reputation points
2023-08-12T15:49:05.47+00:00

Hello

I am new to ADS.

I have basic tasks: analyze slow queries, monitor current server status and etc. I think that ADS extension: SQL Server Profiles should fit my need. Hence I installed. I don't have experience how to use it hence I browsed some documentation and able to Start/Stop it but I'm confused ... what's the next step?

First ... I don't see the option to save results. I assume it should be XEL file saved locally ... but I don't have it ..

Well .. my request is: could you please in a high level to explain me the workflow of usage of this extension. E.g. I optimized some query and want to compare performance and that type of task. How could I do it. As I mentioned above .. I'm stopped on the step of saving the session

Thanks

SQL Server
SQL Server
A family of Microsoft relational database management and analysis systems for e-commerce, line-of-business, and data warehousing solutions.
13,113 questions
Azure Data Studio
Azure Data Studio
A cross-platform database tool for data professionals using on-premises and cloud data platforms on Windows, macOS, and Linux.
104 questions
0 comments No comments
{count} votes

Accepted answer
  1. Erland Sommarskog 103.9K Reputation points MVP
    2023-08-12T17:41:12.34+00:00

    When it comes to saving, I found that this is currently not supported, see https://github.com/microsoft/azuredatastudio/issues/20219 Bear in mind that the current version is 0.1.1, a number that suggests that it is far from feature complete.

    As for analysing slow queries that is a wide topic and a Profiler like this is just a tool. As long as you are only running queries in Azure Data Studio, you don't really need it, since you can wrap the queries in SELECT sysdatettime() to measure the execution time.

    But say that you are running an application, and you want to know that takes time. Then you can set up SQL Profiler, filter for that application and see what calls it are making.

    If you are running a stored procedure, you may want to see the individual statements inside in the procedure. There are events to capture this, but SQL Profiler in ADS does not yet seem to support them. There are other Profiler tools you can use for this purpose. Before I start to suggest too much: are you on Windows or are you on some other platform?

    2 people found this answer helpful.

1 additional answer

Sort by: Most helpful
  1. Javier Villegas 900 Reputation points MVP
    2023-08-12T18:41:07.8966667+00:00

    Hi @Susja

    Please note that SQL Server Profiler extension is still in Preview. You can still use profiler from SSMS or Extended Events to , for example, identify long running statements and do query optimization

    Regards

    Javier