Tuesday, May 12, 2026

SQL 2025 master class LAB 18 profiler


open smss

connect to msqlserver

create new query with following data and run 

 USE [AdventureWorks2025]

EXECUTE dbo.uspGetEmployeeManagers 1

GO

SELECT
*

FROM Production.Product ;

GO

SELECT
*

FROM Production.Product

WHERE [ReorderPoint] > 500

AND [ReorderPoint] < 1000 ;

GO

SELECT
*

FROM Production.ProductInventory ;

GO

SELECT
*

FROM Sales.SalesOrderDetail ;

GO

SELECT *FROM Production.TransactionHistory ; 

GO

 

Microsoft sql server tools 22

Sql profiler 22  tools > connect to database engine windows instance

File > New Trace tS\

Name tracelab

 

start performance  

Data Collector Serts

System Performance

Performance counters

start 

start trace

run query

stop trace

save as trace file

stop data collector set

save as log 

open as trace file

open data collection log 

 %systemdrive%\perflogs\System\Performance

--with thanks and acknowledgement to

http://assets.red-gate.com/community/books/mastering-profiler-ebook.pdf

 --housekeeping