Skip to content

SQL truncated at lines starting with "go" in migrationBuilder.Sql #34183

Closed

Description

@chrisclaytonrazor

File a bug

I can still reproduce #32457 in v8.0.6

Example script in migrationBuilder.Sql

SELECT
    ColumnA,
    ColumnB,
    GoodColumn,
    ColumnC
FROM 
   Table

Is truncated before executing to

SELECT
    ColumnA,
    ColumnB,

And fails with Incorrect syntax near ','

If I change to:

SELECT
    ColumnA,
    ColumnB,
    [GoodColumn],
    ColumnC
FROM 
   Table

It works. I presume it looks for lines starting with go?

Include provider and version information

EF Core version: 8.0.6
Database provider: (e.g. Microsoft.EntityFrameworkCore.SqlServer)
Target framework: .NET 8
Operating system: Windows
IDE: Latest Visual Studio and Rider.

Activity

  1. assigned and unassigned on Jul 9, 2024
  2. added this to the Backlog milestone on Aug 12, 2024
  3. removed their assignment
    on Aug 12, 2024
  4. added theissue type on Jun 15, 2025
  5. added a commit that references this issue on Oct 8, 2026
    69008aa
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions