Question

Trying to install sp_BlitzCache on SQL Server 2008, I get:

Msg 102, Level 15, State 1, Procedure sp_BlitzCache, Line 2705 Incorrect syntax near '.'.
Msg 102, Level 15, State 1, Procedure sp_BlitzCache, Line 2715 Incorrect syntax near '.'.
Msg 102, Level 15, State 1, Procedure sp_BlitzCache, Line 2865 Incorrect syntax near '.'.

Line 2705 is :

/* END Testing using XML nodes to speed up processing */

Line 2865 is the FROM line in:

/* Set configuration values */
SELECT  @ctp = NULLIF(CAST(value AS INT), 0)
FROM    sys.configurations
WHERE   name = 'cost threshold for parallelism'
OPTION (RECOMPILE);

It appears to be version 5.5

The SQL Server version is 10.0.6000.29.

When I page through the code, the first error I see highlighted is on #1162 in the source file: (and 4 more after that.)

SELECT CAST('' AS XML).value('xs:hexBinary( substring(sql:variable("@individual"), sql:column("t.pos")) )', 'varbinary(max)')
"Cannot call methods on int."

The next error is on line 2032 in the source - a select statement with

q.n.query('.') AS statement
Can't find q as a column, function, or q.n.query is ambiguous.

After that there are more cascading errors.

Était-ce utile?

La solution

You're running it in a database in 2000 or 2005 compatibility level, which isn't supported.

Licencié sous: CC-BY-SA avec attribution
Non affilié à dba.stackexchange
scroll top