Neoview Command Interface (NCI) Guide (R2.4)

Displaying Executed Commands
To display commands that were recently executed in the NCI session, enter the HISTORY
command. The HISTORY command associates each command with a number that you can use
to reexecute or edit the command with the FC command. See “Editing and Reexecuting a
Command” (page 66).
For example, this HISTORY command displays a maximum of 100 commands that were entered
in the session:
SQL>history
1> set idletimeout 0
2> set schema persnl;
3> select * from project;
SQL>
To save the session history in a user-specified file, enter the SAVEHIST command. For example,
this SAVEHIST command saves the session history in a file named history.txt in the local
directory where you are running NCI:
SQL>savehist history.txt
For more information, see the “HISTORY Command” (page 101) and the “SAVEHIST Command”
(page 117).
Editing and Reexecuting a Command
To edit and re-execute a command in the history buffer of an NCI session, enter the FC command.
To display the commands in the history buffer, use the HISTORY command. See “Displaying
Executed Commands” (page 66).
For example, this FC command and its delete (D) editing command correct a SELECT statement
that was entered incorrectly:
SQL>fc
SQL>selecct * from employee;
.... d
SQL>select * from employee;
....
Pressing Enter executes the corrected SELECT statement.
For more information, see the “FC Command” (page 96).
Clearing the Interface Window
After entering commands in NCI, you can clear the interface window by using the CLEAR
command. For example, this CLEAR command clears the interface window so that only the
prompt appears at the top of the window:
SQL>clear
For more information, see the “CLEAR Command” (page 91).
Obtaining Help
To display help text for an interface command that is supported in the current operating mode
of NCI, enter the HELP command. For example, this HELP command displays syntax and
examples of the FC command:
SQL>help fc
For more information, see the “HELP Command” (page 101).
66 Running Commands Interactively in the NCI