Tag block of code to exclude from or use different formatting
Allow adding special tags as comments before a block of code (begin - end) to exclude it from being formatted (just indent the whole section together to proper indent level), or perhaps to signal to use a different formatting profile.
i.e. /format exclude/ or /format profile 2/
 Joel Brown
    
 shared this idea
Joel Brown
    
 shared this idea
      
    We would like to let you know that we have released dbForge SQL Complete, v4.5.167 Beta where the ‘Do not format tag’ feature is implemented http://www.devart.com/dbforge/sql/sqlcomplete/download.html
Please see the following examples:
- noformat endnoformat
SELECT a.AbsenceCode, a.Code FROM Absence a
-
— noformat
SELECT a.AbsenceCode, a.Code FROM Absence a
/* endnoformat */
/* noformat /
SELECT a.AbsenceCode, a.Code FROM Absence a
/ endnoformat */
/* noformat */
SELECT a.AbsenceCode, a.Code FROM Absence a
— endnoformat
We will be looking forward to you feedback on the new feature.
- 
       Joel Brown
    
 commented Joel Brown
    
 commentedthanks for this enhancement, just wondering how the causal user would figure out this feature? 
- 
       Joel Brown
    
 commented Joel Brown
    
 commentedFeedback on this feature: it is helpful. I would like to tweak it one bit: proper line indentation should still be applied. Alternatively it could be a an option in the settings, or you may define another keyword for this behavior. thanks. 
- 
       KJ
    
 commented KJ
    
 commentedThis is an awesome idea! Poor Man's T-SQL Formatter uses the quite simple [noformat] .. [/noformat] tags in a comment. It also has a [minify] .. [/minify] option to compact formatting irrespective of legibility. Super useful stuff. I know all this because I was recently forced to use Poor Man's to pre-format a large number (300+) of SQL source files before applying SQL Complete formatter to get around some missing functionality from SQL Complete. devart's formatter is really class-leading, but for the missing stuff (e.g. better handling of arithmetic operators, function parameters, and generalized wrapping) we still have to carefully hand-format. We would love a way to preserve small amounts of hand-formatting while still being able to apply SQL Complete formatter on a regular, automatic basis. 
 
        