Skip to content
Tako Lee edited this page Mar 6, 2014 · 16 revisions
  • Subquery isn't in new line

    Option: fmt032_subquery_in_newline = false, type: TFmtBoolean.

    SELECT SUM (Sales) FROM Store_Information
    WHERE Store_Name IN (SELECT Store_Name FROM Geography
                         WHERE Region_Name = 'West');
  • Subquery in new line

    Option: fmt032_subquery_in_newline = true, type: TFmtBoolean.

    • Start parenthesis in not in newline

      Option: fmt033_subquery_start_parenthesis_in_newline = false, type: TFmtBoolean.

      Option: fmt037_subquery_select_keyword_in_newline = true, type: TFmtBoolean.

      Option: fmt038_subquery_select_keyword_indent = n, type: TFmtBoolean.

      SELECT SUM (Sales) FROM Store_Information
      WHERE Store_Name IN (
              SELECT Store_Name FROM Geography
              WHERE Region_Name = 'West');
    • Start parenthesis is in newline

      Option: fmt033_subquery_start_parenthesis_in_newline = true, type: TFmtBoolean.

      Option: fmt034_subquery_start_parenthesis_indent = n, type: TFmtBoolean.

      Option: fmt037_subquery_select_keyword_in_newline = false, type: TFmtBoolean.

      SELECT SUM (Sales) FROM Store_Information
      WHERE Store_Name IN 
             (SELECT Store_Name FROM Geography
              WHERE Region_Name = 'West');
    • Start parenthesis is in newline

      Option: fmt033_subquery_start_parenthesis_in_newline = true, type: TFmtBoolean.

      Option: fmt034_subquery_start_parenthesis_indent = n, type: TFmtBoolean.

      Option: fmt037_subquery_select_keyword_in_newline = true, type: TFmtBoolean.

      Option: fmt038_subquery_select_keyword_indent = n, type: TFmtBoolean.

      SELECT SUM (Sales) FROM Store_Information
      WHERE Store_Name IN 
             (
               SELECT Store_Name FROM Geography
               WHERE Region_Name = 'West');
    • Start parenthesis is in newline

      Option: fmt033_subquery_start_parenthesis_in_newline = true, type: TFmtBoolean.

      Option: fmt034_subquery_start_parenthesis_indent = n, type: TFmtBoolean.

      Option: fmt037_subquery_select_keyword_in_newline = true, type: TFmtBoolean.

      Option: fmt038_subquery_select_keyword_indent = n, type: TFmtBoolean.

      Option: fmt035_subquery_end_parenthesis_in_newline = true, type: TFmtBoolean.

      Option: fmt036_subquery_end_parenthesis_indent = n, type: TFmtBoolean.

      SELECT SUM (Sales) FROM Store_Information
      WHERE Store_Name IN 
             (
               SELECT Store_Name FROM Geography
               WHERE Region_Name = 'West'
             );
  • Put comparison operator after subquery into new line

    SELECT [CategoryID] AS [CategoryId], 
    FROM   [dbo].[Categories] 
    WHERE  (SELECT Sum([LPA_L1].[UnitsInStock]) AS [LPAV_] 
                 FROM   (SELECT [CategoryID] AS [CategoryId], 
                         FROM   [dbo].[Products] 
                         WHERE  [Products].[CategoryID] 
                              = [Categories].[CategoryID] ) [LPA_L1])
           > @p2 

Clone this wiki locally