How do I use PROMPT NOPROMPT COMPLETE and REQUIRED options with SQLSERVER?
These arguments can be used with ODBC engine for connecting to an SQLServer database on Windows. They allow the libname to pick up some/all of the local DSN configuration created in the Windows ODBC Data Sources utility, and potentially to tell Windows to pop up a prompt for any missing values.
You specify these arguments in the libname step or in the connect string, e.g.:
libname out ODBC NOPROMPT="DRIVER=SQL Server;SERVER=UkSrv1;DATABASE=ReportsDB";
connect to odbc(noprompt="driver={SQL Server}; Server=SERVER15; Database=dbLive;uid=user01;pwd=hidden");
PROMPT - user will be always be prompted to review and edit/complete any missing parameters before the SQL connection in made.
NOPROMPT - user will NOT be prompted...all the parameters must be provided in the libname or connect string.
COMPLETE - user will be only prompted if some values are missing.
REQUIRED - user will be prompted if some values are missing...but can only change the listed values.