BUG: OPENJSON( ) and Square Brackets

ArnieRowlandArnieRowland Posts: 9 Bronze 1
edited January 27, 2020 6:55PM in SQL Prompt
SSMS, ADD Square Brackets is enabled. Most current SQL Prompt and SSMS upgrades.

When SQL Prompt formats, and adds Square Brackets, as desired, the following error is encountered with OPENJSON( ).

In a multi-table JOIN that includes an OPENJSON( ) table as a JOIN participant, SQL Prompt will add Square Brackets to [OPENJSON]( ). That will then cause the query to fail. 

Square Brackets are  NOT added when OPENJSON( ) is the ONLY table in a query.

Comments

Sign In or Register to comment.