Posted on 2014-01-08
I have a sql server stored procedure that was created in 2000.
I'm currently using Sql Server 2008 R2.
The database this stored procedure is located in is currently set to a compatibility_level = 100
When I run the stored procedure I get the error shown below.
The query uses non-ANSI outer join operators ("*=" or "=*"). To run this query without modification, please set the compatibility level for current database to 80, using the SET COMPATIBILITY_LEVEL option of ALTER DATABASE. It is strongly recommended to rewrite the query using ANSI outer join operators (LEFT OUTER JOIN, RIGHT OUTER JOIN). In the future versions of SQL Server, non-ANSI join operators will not be supported even in backward-compatibility modes.
When I change the compatibility level of my database to compatibility_level = 80 then my query runs fine.
I don't want to change the compatibility level. I want my compatibiliy_level to remain at 100.
So according to the error message I get, I figure my only option is to rewrite the query.
It's kind of a complex query.
Is there a tool out there? Whether its a free or commercial tool,
where I can just paste my existing query in and it will refactor my query to a more current syntax that will be able to run on my database when I set it to compatibility_level = 100