Hi,
Thanks for a great plugin, I've purchased the pro version!
I did an upgrade to the latest version and have some problems I hope to get resolved. I have version 6.0.2.8 (64 bit) with Notepad++ version 8.1.9.3 (64 bit). It's regarding MS SQL.
This is example code:
CREATE TABLE _TempTable ( Column1_asdasdasdasdasdasdasdasdasdasd VARCHAR(256) NOT NULL, Column2 NVARCHAR(100) NOT NULL, Column3 NVARCHAR(100) NOT NULL, Column4 NVARCHAR(100) NOT NULL, Column5 NVARCHAR(100) NOT NULL, Column6 NVARCHAR(100) NOT NULL, Column7 DATETIME2 NULL, Column8 INT NULL, Column9 DATETIME2 NULL, Column10 INT NULL, Column11 UNIQUEIDENTIFIER NOT NULL, CONSTRAINT UC_Column11 UNIQUE(Column11), Column12 BIT, Column13 BIT, Column14 BIT, Column15 DATETIME2 NULL ) INSERT INTO _TempTable( Column2 ) SELECT Column2 FROM _OtherTempTable O INNER JOIN _OtherTempTable2 PB WITH (NOLOCK )
See attached file on how its formatted.
It does not recognize DATETIME2, UNIQUEIDENTIFIER or BIT as datatype as far as I can see, and therefore not indenting correctly.
Also I have specified to not do a lineshift after INSERT INTO, but it does.
How can I avoid lineshift before query hint WITH?
Thanks!
Regards,
jmelhus
Hi melhus,
thanks for your feedback.
I will add DATETIME2 and UNIQUEIDENTIFIER as datatype
the current option INTO relates to FETCH .... INTO
I will add a new Option for linebreak after INSERT INTO
REgards
Guido
@jmelhus, datatype added to the new release. Will do some testing and publish shortly
Thank you very much!
@jmelhus please download the new version 6.0.3.3 64-bit and give it a try
DATETIME2 and UNIQUEIDENTIFIER have been added. BIT was already in the list of variable types
The reason why the BIT keyword is not indented is that the line with the CONSTRAINT keyword which does precedd the lines with BIT keywords does not contain a variable type. The var types of Consecutive lines are aligned.
Thank you, it works! Did you also have time to look at query hints with select?
SELECT Col_1 AS Test FROM TestTable TT WITH (NOLOCK)
Is formatted like the attached image.
How can I control format of query hints like WITH?
I would like to keep the query hint with keyword and parenthesis on the same line as the FROM.
@admin Thanks! I can only find the new version as 32-bit, would you please publish as 64-bit as well? Thanks in advance!