Skip to content

Move config option section to Modern CLI and enhance Legacy CLI section

8e53e79
Select commit
Loading
Failed to load commit list.
Open

Add copilot-instructions.md for go-sqlcmd repository #611

Move config option section to Modern CLI and enhance Legacy CLI section
8e53e79
Select commit
Loading
Failed to load commit list.
Azure Pipelines / microsoft.go-sqlcmd failed Nov 26, 2025 in 4m 35s

Build #20251126.3 had test failures

Details

Tests

  • Failed: 11 (1.68%, 11 new, 0 recurring)
  • Passed: 622 (94.96%)
  • Other: 22 (3.36%)
  • Total: 655
Code coverage

  • 2859 of 3524 line covered (81.13%)

Annotations

Check failure on line 19 in Build log

See this annotation in the file changed.

@azure-pipelines azure-pipelines / microsoft.go-sqlcmd

Build log #L19

There are one or more test failures detected in result files. Detailed summary of published test results can be viewed in the Tests tab.

Check failure on line 1 in TestRunInputFiles

See this annotation in the file changed.

@azure-pipelines azure-pipelines / microsoft.go-sqlcmd

TestRunInputFiles

Failed
Raw output
=== RUN   TestRunInputFiles
    sqlcmd_test.go:248: 
        	Error Trace:	/home/vsts/work/1/s/cmd/sqlcmd/sqlcmd_test.go:248
        	Error:      	Received unexpected error:
        	            	mssql: login error: Cannot open server 'ssmstests' requested by the login. Client with IP address '172.210.53.114' is not allowed to access the server.  To enable access, use the Azure Management Portal or run sp_set_firewall_rule on the master database to create a firewall rule for this IP address or address range.  It may take up to five minutes for this change to take effect.
        	Test:       	TestRunInputFiles
        	Messages:   	run
    sqlcmd_test.go:249: 
        	Error Trace:	/home/vsts/work/1/s/cmd/sqlcmd/sqlcmd_test.go:249
        	Error:      	Not equal: 
        	            	expected: 0
        	            	actual  : 1
        	Test:       	TestRunInputFiles
        	Messages:   	exitCode
    sqlcmd_test.go:252: 
        	Error Trace:	/home/vsts/work/1/s/cmd/sqlcmd/sqlcmd_test.go:252
        	Error:      	Not equal: 
        	            	expected: "100\n\n(1 row affected)\n100\n\n(1 row affected)\n"
        	            	actual  : "mssql: login error: Cannot open server 'ssmstests' requested by the login. Client with IP address '172.210.53.114' is not allowed to access the server.  To enable access, use the Azure Management Portal or run sp_set_firewall_rule on the master database to create a firewall rule for this IP address or address range.  It may take up to five minutes for this change to take effect.\nmssql: login error: Cannot open server 'ssmstests' requested by the login. Client with IP address '172.210.53.114' is not allowed to access the server.  To enable access, use the Azure Management Portal or run sp_set_firewall_rule on the master database to create a firewall rule for this IP address or address range.  It may take up to five minutes for this change to take effect.\n"
        	            	
        	            	Diff:
        	            	--- Expected
        	            	+++ Actual
        	            	@@ -1,7 +1,3 @@
        	            	-100
        	            	+mssql: login error: Cannot open server 'ssmstests' requested by the login. Client with IP address '172.210.53.114' is not allowed to access the server.  To enable access, use the Azure Management Portal or run sp_set_firewall_rule on the master database to create a firewall rule for this IP address or address range.  It may take up to five minutes for this change to take effect.
        	            	+mssql: login error: Cannot open server 'ssmstests' requested by the login. Client with IP address '172.210.53.114' is not allowed to access the server.  To enable access, use the Azure Management Portal or run sp_set_firewall_rule on the master database to create a firewall rule for this IP address or address range.  It may take up to five minutes for this change to take effect.
        	            	 
        	            	-(1 row affected)
        	            	-100
        	            	-
        	            	-(1 row affected)
        	            	-
        	Test:       	TestRunInputFiles
        	Messages:   	Incorrect output from run
--- FAIL: TestRunInputFiles (0.93s)

Check failure on line 1 in TestUnicodeOutput

See this annotation in the file changed.

@azure-pipelines azure-pipelines / microsoft.go-sqlcmd

TestUnicodeOutput

Failed
Raw output
=== RUN   TestUnicodeOutput
    sqlcmd_test.go:270: 
        	Error Trace:	/home/vsts/work/1/s/cmd/sqlcmd/sqlcmd_test.go:270
        	Error:      	Received unexpected error:
        	            	mssql: login error: Cannot open server 'ssmstests' requested by the login. Client with IP address '172.210.53.114' is not allowed to access the server.  To enable access, use the Azure Management Portal or run sp_set_firewall_rule on the master database to create a firewall rule for this IP address or address range.  It may take up to five minutes for this change to take effect.
        	Test:       	TestUnicodeOutput
        	Messages:   	run
    sqlcmd_test.go:271: 
        	Error Trace:	/home/vsts/work/1/s/cmd/sqlcmd/sqlcmd_test.go:271
        	Error:      	Not equal: 
        	            	expected: 0
        	            	actual  : 1
        	Test:       	TestUnicodeOutput
        	Messages:   	exitCode
    sqlcmd_test.go:280: 
        	Error Trace:	/home/vsts/work/1/s/cmd/sqlcmd/sqlcmd_test.go:280
        	Error:      	Not equal: 
        	            	expected: []byte{0xff, 0xfe, 0x53, 0x0, 0x69, 0x0, 0x6d, 0x0, 0x70, 0x0, 0x6c, 0x0, 0x69, 0x0, 0x66, 0x0, 0x69, 0x0, 0x65, 0x0, 0x64, 0x0, 0x43, 0x0, 0x68, 0x0, 0x69, 0x0, 0x6e, 0x0, 0x65, 0x0, 0x73, 0x0, 0x65, 0x0, 0xa, 0x0, 0x2d, 0x0, 0x2d, 0x0, 0x2d, 0x0, 0x2d, 0x0, 0x2d, 0x0, 0x2d, 0x0, 0x2d, 0x0, 0x2d, 0x0, 0x2d, 0x0, 0x2d, 0x0, 0x2d, 0x0, 0x2d, 0x0, 0x2d, 0x0, 0x2d, 0x0, 0x2d, 0x0, 0x2d, 0x0, 0x2d, 0x0, 0xa, 0x0, 0x28, 0x63, 0x28, 0x63, 0x9, 0x55, 0xc0, 0x54, 0x91, 0x76, 0x4c, 0x76, 0x3c, 0x85, 0xee, 0x77, 0x20, 0x0, 0x20, 0x0, 0x20, 0x0, 0x20, 0x0, 0x20, 0x0, 0x20, 0x0, 0x20, 0x0, 0x20, 0x0, 0x20, 0x0, 0xa, 0x0, 0xa, 0x0, 0x28, 0x0, 0x31, 0x0, 0x20, 0x0, 0x72, 0x0, 0x6f, 0x0, 0x77, 0x0, 0x20, 0x0, 0x61, 0x0, 0x66, 0x0, 0x66, 0x0, 0x65, 0x0, 0x63, 0x0, 0x74, 0x0, 0x65, 0x0, 0x64, 0x0, 0x29, 0x0, 0xa, 0x0}
        	            	actual  : []byte{0xff, 0xfe, 0x6d, 0x0, 0x73, 0x0, 0x73, 0x0, 0x71, 0x0, 0x6c, 0x0, 0x3a, 0x0, 0x20, 0x0, 0x6c, 0x0, 0x6f, 0x0, 0x67, 0x0, 0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0, 0x31, 0x0, 0x34, 0x0, 0x27, 0x0, 0x20, 0x0, 0x69, 0x0, 0x73, 0x0, 0x20, 0x0, 0x6e, 0x0, 0x6f, 0x0, 0x74, 0x0, 0x20, 0x0, 0x61, 0x0, 0x6c, 0x0, 0x6c, 0x0, 0x6f, 0x0, 0x77, 0x0, 0x65, 0x0, 0x64, 0x0, 0x20, 0x0, 0x74, 0x0, 0x6f, 0x0, 0x20, 0x0, 0x61, 0x0, 0x63, 0x0, 0x63, 0x0, 0x65, 0x0, 0x73, 0x0, 0x73, 0x0, 0x20, 0x0, 0x74, 0x0, 0x68, 0x0, 0x65, 0x0, 0x20, 0x0, 0x73, 0x0, 0x65, 0x0, 0x72, 0x0, 0x76, 0x0, 0x65, 0x0, 0x72, 0x0, 0x2e, 0x0, 0x20, 0x0, 0x20, 0x0, 0x54, 0x0, 0x6f, 0x0, 0x20, 0x0, 0x65, 0x0, 0x6e, 0x0, 0x61, 0x0, 0x62, 0x0, 0x6c, 0x0, 0x65, 0x0, 0x20, 0x0, 0x61, 0x0, 0x63, 0x0, 0x63, 0x0, 0x65, 0x0, 0x73, 0x0, 0x73, 0x0, 0x2c, 0x0, 0x20, 0x0, 0x75, 0x0, 0x73, 0x0, 0x65, 0x0, 0x20, 0x0, 0x74, 0x0, 0x68, 0x0, 0x65, 0x0, 0x20, 0x0, 0x41, 0x0, 0x7a, 0x0, 0x75, 0x0, 0x72, 0x0, 0x65, 0x0, 0x20, 0x0, 0x4d, 0x0, 0x61, 0x0, 0x

Check failure on line 1 in TestQueryAndExit

See this annotation in the file changed.

@azure-pipelines azure-pipelines / microsoft.go-sqlcmd

TestQueryAndExit

Failed
Raw output
=== RUN   TestQueryAndExit
    sqlcmd_test.go:351: 
        	Error Trace:	/home/vsts/work/1/s/cmd/sqlcmd/sqlcmd_test.go:351
        	Error:      	Received unexpected error:
        	            	mssql: login error: Cannot open server 'ssmstests' requested by the login. Client with IP address '172.210.53.114' is not allowed to access the server.  To enable access, use the Azure Management Portal or run sp_set_firewall_rule on the master database to create a firewall rule for this IP address or address range.  It may take up to five minutes for this change to take effect.
        	Test:       	TestQueryAndExit
        	Messages:   	run
    sqlcmd_test.go:352: 
        	Error Trace:	/home/vsts/work/1/s/cmd/sqlcmd/sqlcmd_test.go:352
        	Error:      	Not equal: 
        	            	expected: 0
        	            	actual  : 1
        	Test:       	TestQueryAndExit
        	Messages:   	exitCode
    sqlcmd_test.go:355: 
        	Error Trace:	/home/vsts/work/1/s/cmd/sqlcmd/sqlcmd_test.go:355
        	Error:      	Not equal: 
        	            	expected: "100 val2\n\n(1 row affected)\n"
        	            	actual  : "mssql: login error: Cannot open server 'ssmstests' requested by the login. Client with IP address '172.210.53.114' is not allowed to access the server.  To enable access, use the Azure Management Portal or run sp_set_firewall_rule on the master database to create a firewall rule for this IP address or address range.  It may take up to five minutes for this change to take effect.\nmssql: login error: Cannot open server 'ssmstests' requested by the login. Client with IP address '172.210.53.114' is not allowed to access the server.  To enable access, use the Azure Management Portal or run sp_set_firewall_rule on the master database to create a firewall rule for this IP address or address range.  It may take up to five minutes for this change to take effect.\n"
        	            	
        	            	Diff:
        	            	--- Expected
        	            	+++ Actual
        	            	@@ -1,4 +1,3 @@
        	            	-100 val2
        	            	+mssql: login error: Cannot open server 'ssmstests' requested by the login. Client with IP address '172.210.53.114' is not allowed to access the server.  To enable access, use the Azure Management Portal or run sp_set_firewall_rule on the master database to create a firewall rule for this IP address or address range.  It may take up to five minutes for this change to take effect.
        	            	+mssql: login error: Cannot open server 'ssmstests' requested by the login. Client with IP address '172.210.53.114' is not allowed to access the server.  To enable access, use the Azure Management Portal or run sp_set_firewall_rule on the master database to create a firewall rule for this IP address or address range.  It may take up to five minutes for this change to take effect.
        	            	 
        	            	-(1 row affected)
        	            	-
        	Test:       	TestQueryAndExit
        	Messages:   	Incorrect output from run
--- FAIL: TestQueryAndExit (0.50s)

Check failure on line 1 in TestUnicodeInput

See this annotation in the file changed.

@azure-pipelines azure-pipelines / microsoft.go-sqlcmd

TestUnicodeInput

Failed
Raw output
=== RUN   TestUnicodeInput
    sqlcmd_test.go:319: 
        	Error Trace:	/home/vsts/work/1/s/cmd/sqlcmd/sqlcmd_test.go:319
        	Error:      	Received unexpected error:
        	            	mssql: login error: Cannot open server 'ssmstests' requested by the login. Client with IP address '172.210.53.114' is not allowed to access the server.  To enable access, use the Azure Management Portal or run sp_set_firewall_rule on the master database to create a firewall rule for this IP address or address range.  It may take up to five minutes for this change to take effect.
        	Test:       	TestUnicodeInput
        	Messages:   	run
    sqlcmd_test.go:320: 
        	Error Trace:	/home/vsts/work/1/s/cmd/sqlcmd/sqlcmd_test.go:320
        	Error:      	Not equal: 
        	            	expected: 0
        	            	actual  : 1
        	Test:       	TestUnicodeInput
        	Messages:   	exitCode
    sqlcmd_test.go:327: 
        	Error Trace:	/home/vsts/work/1/s/cmd/sqlcmd/sqlcmd_test.go:327
        	Error:      	Not equal: 
        	            	expected: "\xff\xfeS\x00i\x00m\x00p\x00l\x00i\x00f\x00i\x00e\x00d\x00C\x00h\x00i\x00n\x00e\x00s\x00e\x00\n\x00-\x00-\x00-\x00-\x00-\x00-\x00-\x00-\x00-\x00-\x00-\x00-\x00-\x00-\x00-\x00-\x00-\x00\n\x00(c(c\tU\xc0T\x91vLv<\x85\xeew \x00 \x00 \x00 \x00 \x00 \x00 \x00 \x00 \x00\n\x00\n\x00(\x001\x00 \x00r\x00o\x00w\x00 \x00a\x00f\x00f\x00e\x00c\x00t\x00e\x00d\x00)\x00\n\x00"
        	            	actual  : "\xff\xfem\x00s\x00s\x00q\x00l\x00:\x00 \x00l\x00o\x00g\x00i\x00n\x00 \x00e\x00r\x00r\x00o\x00r\x00:\x00 \x00C\x00a\x00n\x00n\x00o\x00t\x00 \x00o\x00p\x00e\x00n\x00 \x00s\x00e\x00r\x00v\x00e\x00r\x00 \x00'\x00s\x00s\x00m\x00s\x00t\x00e\x00s\x00t\x00s\x00'\x00 \x00r\x00e\x00q\x00u\x00e\x00s\x00t\x00e\x00d\x00 \x00b\x00y\x00 \x00t\x00h\x00e\x00 \x00l\x00o\x00g\x00i\x00n\x00.\x00 \x00C\x00l\x00i\x00e\x00n\x00t\x00 \x00w\x00i\x00t\x00h\x00 \x00I\x00P\x00 \x00a\x00d\x00d\x00r\x00e\x00s\x00s\x00 \x00'\x001\x007\x002\x00.\x002\x001\x000\x00.\x005\x003\x00.\x001\x001\x004\x00'\x00 \x00i\x00s\x00 \x00n\x00o\x00t\x00 \x00a\x00l\x00l\x00o\x00w\x00e\x00d\x00 \x00t\x00o\x00 \x00a\x00c\x00c\x00e\x00s\x00s\x00 \x00t\x00h\x00e\x00 \x00s\x00e\x00r\x00v\x00e\x00r\x00.\x00 \x00 \x00T\x00o\x00 \x00e\x00n\x00a\x00b\x00l\x00e\x00 \x00a\x00c\x00c\x00e\x00s\x00s\x00,\x00 \x00u\x00s\x00e\x00 \x00t\x00h\x00e\x00 \x00A\x00z\x00u\x00r\x00e\x00 \x00M\x00a\x00n\x00a\x00g\x00e\x00m\x00e\x00n\x00t\x00 \x00P\x00o\x00r\x00t\x00a\x00l\x00 \x00o\x00r\x00 \x00r\x00u\x00n\x00 \x00s\x00p\x00_\x00s\x00e\x00t\x00_\x00f\x00i\x00r\x00e\x00w\x00a\x00l\x00l\x00_\x00r\x00u\x00l\x00e\x00 \x00o\x00n\x00 \x00t\x00h\x00e\x00 \x00m\x00a\x00s\x00t\x00e\x00r\x00 \x00d\x00a\x00t\x00a\x00b\x00a\x00s\x00e\x00 \x00t\x00o\x00 \x00c\x00r\x00e\x00a\x00t\x00e\x00 \x00a\x00 \x00f\x00i\x00r\x00e\x00w\x00a\x00l\x00l\x00 \x00r\x00u\x00l\x00e\x00 \x00f\x00o\x00r\x00 \x00t\x00h\x00i\x00s\x00 \x00I\x00P\x00 \x00a\x00d\x00d\x00r\x00e\x00s\x00s\x00 \x00o\x00r\x00 \x00a\x00d\x00d\x00r\x00e\x00s\x00s\x00 \x00r\x00a\x00n\x00g\x00e\x00.\x00 \x00 \x00I\x00t\x00 \x00m\x00a\x00y\x00 \x00t\x00a\x00k\x00e\x00 \x00u\x00p\x00 \x00t\x00o\x00 \x00f\x00i\x00v\x00e\x00 \x00m\x00i\x00n\x00u\x00t\x00e\x00s\x00 \x00f\x00o\x00r\x00 \x00t\x00h\x00i\x00s\x00 \x00c\x00h\x00a\x00n\x00g\x00e\x00 \x00t\x00o\x00 \x00t\x00a\x00k\x00e\x00 \x00e\x00f\x00f\x00e\x00c\x00t\x00.\x00\n\x00m\x00s\x00s\x00q\x00l\x00:\x00 \x00l\x00o\x00g\x00i\x00n\x00 \x00e\x00r\x00r\x00o\x00r\x00:\x00 \x00C\x00a\x00n\x00n\x00o\x00t\x00 \x00o\x00p\x00e\x00n\x00 \x00s\x00e\x00r\x00v\x00e\x00r\x00 \x00'\x00s\x00s\x00m\x00s\x00t\x00e\x00s\x00t\x00s\x00'\x00 \x00r\x00e\x00q\x00u\x00e\x00s\x00t\x00e\x00d\x00 \x00b\x00y\x00 \x00t\x00h\x00e\x00 \x00l\x00o\x00g\x00i\x00n\x00.\x00 \x00C\x00l\x00i\x00e\x00n\x00t\x00 \x00w\x00i\x00t\x00h\x00 \x00I\x00P\x00 \x00a\x00d\x00d\x00r\x00e\x00s\x00s\x00 \x00'\x001\x007\x002\x00.\x002\x001\x000\x00.\x005\x003\x00.\x001\x001\x004\x00'\x00 \x00i\x00s\x00 \x00n\x00o\x00t\x00 \x0