When using SQLCMD on windows is there any way to use DSNs?

241 Views Asked by At

Rather than configuring connection information directly through each and every sqlcmd command, looking to use DSNs to have that information stored in a centralized location.

However when referring to the documentation given on sqlcmd:

-D
Interprets the server name provided to -S as a DSN instead of a hostname. For more information, see DSN Support in sqlcmd and bcp in Connecting with sqlcmd.

Note
The -D option is only available on Linux and MacOS clients. On Windows clients, it previously referred to a now-obsolete option which has been removed and is ignored.

Is there anyway on windows to utilize DSNs when using SQLCMD? Seems strange that this functionality would be removed and limited to only MacOS and Linux.

0

There are 0 best solutions below