SoftTree Technologies SoftTree Technologies
Technical Support Forums
RegisterSearchFAQMemberlistUsergroupsLog in
[12.1.277 Pro] - Formatting corrupts code (MSSQL)

 
Reply to topic    SoftTree Technologies Forum Index » SQL Assistant View previous topic
View next topic
[12.1.277 Pro] - Formatting corrupts code (MSSQL)
Author Message
gemisigo



Joined: 11 Mar 2010
Posts: 2112

Post [12.1.277 Pro] - Formatting corrupts code (MSSQL) Reply with quote
For some unknown reason this code
Code:

DECLARE @ma date = CAST(GETDATE() AS date);


becomes
Code:

DECLARE @ma date = .CAST(GETDATE() AS date);


after formatting. It gets a surplus period in front of CAST.
Thu Apr 07, 2022 11:20 am View user's profile Send private message
Mindflux



Joined: 25 May 2013
Posts: 817
Country: United States

Post Reply with quote
Just formatting that line here does not exhibit this issue. Perhaps it's a formatting rule you have in place?
Thu Apr 07, 2022 11:26 am View user's profile Send private message
SysOp
Site Admin


Joined: 26 Nov 2006
Posts: 7857

Post Reply with quote
I'm guessing that somewhere in a custom formatting rule you got 4 dots in place of 3 dots wildcard.
Thu Apr 07, 2022 1:32 pm View user's profile Send private message
gemisigo



Joined: 11 Mar 2010
Posts: 2112

Post Reply with quote
I've thought about that but there are only two consecutive 4-dot combos in the entire sqlassist.sas file. Both are snippet captions, one for MariaDB and the other one for MySQL. The affected formatting is SQL Server. It's been quite a while since I last did major stuff in SQL Server so I'm reasonably certain I didn't change anything in formatting rules recently. I'm not sure but I guess this started after I upgraded to v12.1.

UPDATE: culprit found. I've got a formatting rule for DECLARE
Code:

DECLARE @... ... = ...;


I changed it to
Code:

DECLARE @... = ...;

and does not ruin the code anymore, but I have a vague recollection of having a very good reason for putting that middle set of 3-dots there. Alas, I no longer remember what it was. I'm afraid I'll be enlightened very soon.
Fri Apr 08, 2022 4:02 am View user's profile Send private message
Display posts from previous:    
Reply to topic    SoftTree Technologies Forum Index » SQL Assistant All times are GMT - 4 Hours
Page 1 of 1

 
Jump to: 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


 

 

Powered by phpBB © 2001, 2005 phpBB Group
Design by Freestyle XL / Flowers Online.