Skip to content

Commit 4773044

Browse files
author
David Shiflet (from Dev Box)
committed
fix error msg
1 parent be44da3 commit 4773044

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

.vscode/launch.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
"request": "launch",
2525
"mode" : "auto",
2626
"program": "${workspaceFolder}/cmd/modern",
27-
"args" : ["-S", "sqltools2025-3", "-Ns:sqltools2025-3.redmond.corp.microsoft.com", "-Q", "select top 8 name from sys.all_objects"],
27+
"args" : ["-S", ".", "-Q", "select top 8 name from sys.all_objects"],
2828
},
2929
{
3030
"name" : "Run file query",

cmd/sqlcmd/sqlcmd.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -492,7 +492,7 @@ func normalizeFlags(cmd *cobra.Command) error {
492492
case "mandatory", "yes", "1", "t", "true", "disable", "optional", "no", "0", "f", "false", "strict", "m", "s", "o":
493493
return pflag.NormalizedName(name)
494494
default:
495-
err = invalidParameterError("-N", v, "m[andatory]", "yes", "1", "t[rue]", "disable", "o[ptional]", "no", "0", "f[alse]")
495+
err = invalidParameterError("-N", v, "m[andatory]", "yes", "1", "t[rue]", "disable", "o[ptional]", "no", "0", "f[alse]", "s[trict]")
496496
return pflag.NormalizedName("")
497497
}
498498
case errorsToStderr:

cmd/sqlcmd/sqlcmd_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,7 @@ func TestInvalidCommandLine(t *testing.T) {
161161
{[]string{"-P"}, "'-P': Missing argument. Enter '-?' for help."},
162162
{[]string{"-;"}, "';': Unknown Option. Enter '-?' for help."},
163163
{[]string{"-t", "-2"}, "'-t -2': value must be greater than or equal to 0 and less than or equal to 65534."},
164-
{[]string{"-N", "invalid"}, "'-N invalid': Unexpected argument. Argument value has to be one of [m[andatory] yes 1 t[rue] disable o[ptional] no 0 f[alse]]."},
164+
{[]string{"-N", "invalid"}, "'-N invalid': Unexpected argument. Argument value has to be one of [m[andatory] yes 1 t[rue] disable o[ptional] no 0 f[alse] s[trict]]."},
165165
}
166166

167167
for _, test := range commands {

0 commit comments

Comments
 (0)