WinSQL » Knowledge base
|Subject:||Passing a connection string from command line?|
|Creation date:||7/29/09 4:35 PM|
|Last modified on:||7/29/09 4:35 PM|
Passing connection string from command line
Use the following syntax on a command line to pass a connection string.
winsql "-cDRIVER=SQL Server;SERVER=(local);Trusted_Connection=Yes"
Another way of specifying a connection string is to use it as a DSN name. For example:winsql "-dDSN=YourDSNName" -p-1 -u-1
The above example demonstrate how to connect to a DSN called YourDSNName
. User id and password is set to -1, which means these values will be read from the DSN manager.
Add a comment to this document
Do you have a helpful tip related to this document that you'd like to share
with other users? Please add it below. Your name and tip will appear at the
end of the document text.