Skip to content
No results
We use cookies to ensure that we give you the best experience on our website.

# SQL FORMATTER OPTION: SUBQUERY NEWLINE BEFORE COMPARISON OPERATOR

- admin
- September 27, 2011
- format option, sql pretty printer, v238

This format option control whether put a blank line before comparison operator when it follows a subquery.

name: Subquery_Newline_Before_ComparisonOperator, default is false

setting path: subquery -> Linebreak before comparison operator

SELECT c.[Categoryid] AS [categoryid],
c.[Categoryname],
c.[Picture]
FROM [northwind].[dbo].[CATEGORIES] c
WHERE (((( (SELECT Sum([lpa_l1].[Unitsinstock]) AS [lpav_]
FROM (SELECT p.[Categoryid] AS [categoryid],
p.[Unitsonorder]
FROM [northwind].[dbo].[PRODUCTS] p
WHERE (( p.[Categoryid] = c.[Categoryid] ))) [lpa_l1]) > @p2 ))))

After set Subquery_Newline_Before_ComparisonOperator to true, SQL will be formatted like this:

SELECT c.[Categoryid] AS [categoryid],
c.[Categoryname],
c.[Picture]
FROM [northwind].[dbo].[CATEGORIES] c
WHERE (((( (SELECT Sum([lpa_l1].[Unitsinstock]) AS [lpav_]
FROM (SELECT p.[Categoryid] AS [categoryid],
p.[Unitsonorder]
FROM [northwind].[dbo].[PRODUCTS] p
WHERE (( p.[Categoryid] = c.[Categoryid] ))) [lpa_l1])
> @p2 ))))

### Newsletter Updates

Enter your email address below to subscribe to our newsletter

I accept the Privacy Policy

### Related Posts

#### NEW RELEASE: SQL PRETTY PRINTER VERSION 3.3.3

- September 19, 2012

#### NEW RELEASE: SQL PRETTY PRINTER VERSION 3.3.2

- July 18, 2012

#### SQL Pretty Printer works when Multi-SSMS installed

- July 5, 2012