INF: xp_cmdshell Does Not Retrieve User Input

ID: Q115184


The information in this article applies to:
  • Microsoft SQL Server versions 4.2x, 6.0, 6.5


SUMMARY

Programs that require user input should not be executed through the extended stored procedure xp_cmdshell. xp_cmdshell does not support running MS-DOS programs that require user input.


MORE INFORMATION

There is no way to get the user input from any DB-Library (DB-Lib) client utility to the server. xp_cmdshell was designed to suppress the console window on the server and not allow user input. It will run internal MS-DOS commands and 32-bit programs that require user input and return back to the client utility, but there is no way to provide user input back to the program. Running external MS-DOS commands that require this input will cause the DB-Library client to wait indefinitely for this input and never return control to the client. The SQL Server process will remain active and cannot be terminated using the Kill command.

xp_cmdshell was not designed to allow user input to programs. To achieve this functionality, a new extended stored procedure can be written.

Additional query words: Windows NT

Keywords : kbprg kbSQLServ600 kbSQLServ650 SSrvWinNT
Version : winnt:4.2x,6.0,6.5
Platform : winnt
Issue type : kbinfo


Last Reviewed: February 2, 2000
© 2000 Microsoft Corporation. All rights reserved. Terms of Use.