About

This tool was created for everyone who need to optimize parameterized SQL queries caught by SQL Profiler, which are wrapped by „exec sp_executesql“. If you have experiences with optimization of SQL queries, you probably know that often you have to manually reformat SQL query from "exec sp_executesql..." to standard SQL, which is suitable for monitoring execution plans in SSMS. If you do this more times per day, you spent much time by rewriting the queries. And now you have this tool, which helps you to reformat SQL queries automatically and be more productive.

Example

You have query caught by SQL Profiler like this:
exec sp_executesql N'
SELECT a.Id, a.Name, a.NestingLevel, a.ParentId
FROM Categories AS a WHERE a.NestingLevel = @NestingLevel
',N'@NestingLevel int',@NestingLevel = 0
But you need raw SQL query like this:
declare @NestingLevel int
set @NestingLevel = 0
SELECT a.Id, a.Name, a.NestingLevel, a.ParentId
FROM Categories AS a
WHERE a.NestingLevel = @NestingLevel
What you have to do? just use this tool :-)