Search notes:

SQL*Plus: HOST

host executes a shell (or, on Windows, cmd.exe) command without leaving or terminating SQL*Plus.
The (stdout) output of the command is printed into the SQL*Plus console.
On Unix, host can be abbreviated with an exclamation mark (!).
On Windows, host can be abbreviated with a dollar sign ($).
host shell-command
$ windows-cmd-command
! unix-shell-command

Restriction level

The host command is disabled if the restriction level is set to 1 or more:
C:\> sqlplus -r 1 rene/rene

SQL*Plus: Release 19.0.0.0.0 - Production on Mon Apr 11 15:41:09 2022
Version 19.3.0.0.0

Copyright (c) 1982, 2019, Oracle.  All rights reserved.

Last Successful login time: Mon Apr 11 2022 15:23:16 +02:00

Connected to:
Oracle Database 19c Enterprise Edition Release 19.0.0.0.0 - Production
Version 19.3.0.0.0

SQL> host dir
SP2-0738: Restricted command "host" not available

See also

SQL*Plus

Index