Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

Line counter overflows after 65535 lines

Open
#814 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
55/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Active
Tech stack
go
Domain
cli

Research direction

Reproduce the issue through the sqlcmd -i file.sql entry point with a script exceeding 65,535 lines, then trace how input line numbers are counted and reported in the error message. Done means an error on line 66,148 reports line 66,148 rather than an overflowed value.

Written by the indexing model from the issue text.

Description

Suppose you run a script with sqlcmd -i file.sql and you have an error in its 66148 line.
sqlcmd will report a wrong line in an error message.

Msg 208, Level 16, State 1, Server mssql\SQLEXPRESS, Line 613
Invalid object name 'default.dbo.ASSETS_EXTERNAL'.

It seems that the counter overflows. Not a huge deal, but took an hour of my time today :/

Dominant language
Go
Stars
595
Forks
91
Avg merge
9h 35m
Merged PRs (30d)
1

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from microsoft/go-sqlcmd

All issues in microsoft/go-sqlcmd

Similar issues

More Go issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.