Skip to content

[FORMATTING] GO ALTER in same line... #903

@EuSouVoce

Description

@EuSouVoce

Input data

Which SQL and options did you provide as input?

USE [DBNAME]
GO
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
ALTER PROCEDURE [dbo].[sp_NAME] @param INT ....

Expected Output

USE [DBNAME]
GO
SET
ANSI_NULLS ON
GO
SET
QUOTED_IDENTIFIER ON
GO
ALTER PROCEDURE [dbo].[sp_NAME] @param INT ....

Actual Output

USE [DBNAME]
GO
SET
ANSI_NULLS ON
GO
SET
QUOTED_IDENTIFIER ON
GO ALTER  -- <---- HERE
PROCEDURE [dbo].[sp_NAME] @param INT ....

Usage

  • How are you calling / using the library?
    Vscode ALT SHIFT F with TransactSQL selected ad default setting on settings
  • What SQL language(s) does this apply to?
    Transact SQL
  • Which SQL Formatter version are you using?
    Latest on vscode.

This throws an error on the SSMS as invalid and prevents execution of the sql script.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions