Databases Reference
In-Depth Information
- - keep this to force a new optimization
OPTION ( RECOMPILE )
GO
SELECT *
INTO after_query_transformation_stats
FROM sys . dm_exec_query_transformation_stats
GO
SELECT a . name , ( a . promised - b . promised ) as promised
FROM before_query_transformation_stats b
JOIN after_query_transformation_stats a
ON b . name = a . name
WHERE b . succeeded <> a . succeeded
DROP TABLE before_query_transformation_stats
DROP TABLE after_query_transformation_stats
Listing 5-5.
For example, testing with a very simple AdventureWorks query like the following, which
is already included in the code in Listing 5-5 ...
SELECT * FROM dbo . DatabaseLog
Listing 5-6.
... will show that the following transformation rules are being used.
name
promised
GetIdxToRng
1
GetToTrivialScan
1
Table 5-5.
 
Search WWH ::




Custom Search