SQLPrompt format crashes crashes ssms
gokhanvarol@gmail.com
Posts: 12
Formatting the snipplet with sqlprompt crashes ssms. Please advise
CREATE TABLE #ChangedKeysChildren
(
CntyCd CHAR(5) NULL
, PclId VARCHAR(45) NULL
, PclSeqNbr TINYINT NULL
,NameSeq tinyint NULL
,BEFORE_FullName] varchar(60) NULL
,AFTER_FullName] varchar(60) NULL
)
CREATE TABLE #ChangedKeysChildren
(
CntyCd CHAR(5) NULL
, PclId VARCHAR(45) NULL
, PclSeqNbr TINYINT NULL
,NameSeq tinyint NULL
,BEFORE_FullName] varchar(60) NULL
,AFTER_FullName] varchar(60) NULL
)
Comments
if you remove the un enclosed square brackets
CREATE TABLE #ChangedKeysChildren
(
CntyCd CHAR(5) NULL
, PclId VARCHAR(45) NULL
, PclSeqNbr TINYINT NULL
,NameSeq tinyint NULL
,BEFORE_FullName varchar(60) NULL
,AFTER_FullName varchar(60) NULL
)
or close the square brackets
CREATE TABLE #ChangedKeysChildren
(
CntyCd CHAR(5) NULL
, PclId VARCHAR(45) NULL
, PclSeqNbr TINYINT NULL
,NameSeq tinyint NULL
,[BEFORE_FullName] varchar(60) NULL
,[AFTER_FullName] varchar(60) NULL
)
Format SQL works as expected.
Product Support
Red Gate Software
This piece of code was part of a longer (over 4500 lines) stored procedure which kept crashing on format, eventually I spent the time and find out what's crashing sqlprompt and posted here.
I agree with the original poster - SQL Prompt ==> format SQL should NEVER kill SSMS of any vintage.
Decide wisely...
Product Support
Red Gate Software