DB Creation   «Prev 

When you make a mistake

Why Server Manager does not recognize bad commands

The reason that Oracle Server Manager does not recognize bad commands right away is the result of a design decision that was likely made to keep the code simple. The commands that you type into Server Manager can be divided into two groups.
  1. One group consists of commands such as connect, exit, and help, that control the operation of the Server Manager tool.
  2. The other group of commands consists of all possible SQL statements that you could enter.

There are many SQL statements, the syntax can get very complex, and the syntax for a statement sometimes changes from one Oracle release to the next. It would be a major effort to program Server Manager with the exact syntax of every valid SQL statement, and to keep that up-to-date, so the programmers took a shortcut. SQL statements are ultimately executed by the database server, not Server Manager, so they just programmed Server Manager to send any SQL statements straight to the server, where the server does the work of parsing the statement and validating the syntax.
To further simplify things, Server Manager was programmed to assume that anything other than one of the predefined Server Manager commands was an SQL statement. That is why you can type in a mistake like “exite” and then get stuck, Server Manager is treating it as an SQL statement.

It is interesting that SQL*Plus, which operates in a manner similiar to Server Manager, does not have this problem. The programmers of SQL*Plus programmed it to recognize the first word of all valid SQL statements, so it knows right away that “exite” is a bad command. This is another benefit of Oracle merging Server Manager's functionality into SQL*Plus. In this respect, as in some others, SQL*Plus is the easier tool to use.
Server Manager is Oracle's database administration tool. The graphical component of Server Manager (Server Manager/GUI) allows you to perform database administration tasks with the convenience of a graphical user interface (GUI). The line mode component of Server Manager (Server Manager/LineMode) provides a line mode interface.