-
Notifications
You must be signed in to change notification settings - Fork 8
Functionality
Sql Quantum Leap edited this page Nov 30, 2015
·
7 revisions
Functionality mirroring SQLCMD behavior:
-
-U"User ID" (if not present then-E/ trusted_connection is used) -
-P"Password" -
-S"Server" -
-d"Database name" -
-H"Workstation name" -
-Q"Query" -
-l"Login (i.e. connection) timeout" (default: "15") -
-t"Query (i.e. command) timeout" (default: "30") -
-K"Application intent" -
-NEncrypt Connection (default: false) -
-CTrust Server Certificate (default: false) -
-MMultiSubnet Failover (default: false) -
-o"Output file" -
-s"Column separator" (default: " ") -
-a"packet size" (range: 512 - 32767; default: "4096" {default for .NET SqlConnection = "8000"!}) -
-?/-help/ (no command-line options) Display usage
Functionality unique to SimpleSqlExec:
-
-an"Application name" (default: "Simple SQL Exec") -
-cs"Connection string" -
-ra"Rows Affected file path or User environment variable name" -
-mf"Messages File" -
-oh"Output file handling" (OverWrite, Append, or Error)
Functionality mirroring SQLCMD behavior:
- Support for multiple batches
-
-c"batch separator" (default: "GO") -
-bBatch Abort
-
-
-fcodepage | i:codepage[,o:codepage] | o:codepage[,i:codepage] Input / Output file code pages -
-uencode output file as "Unicode" (UTF-16 Little Endian)
Functionality unique to SimpleSqlExec:
-
-ef"Error File" - write to Messages File as each message comes in
- SQLCMD commands (e.g.
:rto read in a file) - multiple input files via
-i - Passing in variables (
-voption for SQLCMD)
