Altering Oracle's SQL*Plus Help Facility - Page 2
June 4, 2003
Typically, the HELP facility is installed along with the database during normal installation. However, if for some reason you are unable to invoke the HELP facility, it has more than likely not been installed or has been dropped from the installation. In order to install it, follow these simple steps. If these do not quite work, look inside the files within your particular HELP directory with any editor as they will be self-documenting and have changed from version to version.
1. Change to the directory where the help install scripts reside:
2. Log into your database with the SYSTEM account:
3. Drop any lingering help objects:
4. Create the help tables and load help information:
Beefing Up HELP
I cannot quite remember the version of Oracle, but it used to be that the HELP facility also contained quite a few topics that dealt with the DDL, DML, and other administration commands. Please e-mail me if you remember the version that this was de-supported. Anyway, I really miss some of this simple text based help and have since decided to start porting some of the more widely used command syntax back into my HELP facility on the databases that I use. There is really nothing you can't put into this HELP facility and you should seriously start thinking of giving your customers or developers as others call them, the ability to quickly access information that they need without having to page through manuals.
Adding HELP content is really just a four-step process.
1. Load your new content through a SQL script.
2. Rebuild the 'TOPICS' information
3. Rebuild the 'INDEX' information
4. Validate your information
Follow along with the simple formula.
The content I wish to add is for the CREATE TABLESPACE command. All that is required is the TOPIC ('CREATE TABLESPACE'), a unique line number and the text for that line. After you build your topic I would suggest that you save it into its own file, in my case I called it create_tablespace.sql and then if you ever need to rebuild or port this it is very simple.
Remember you must be connected as the SYSTEM user.
In order for the 'HELP TOPICS' command to work and show the new content you just added, you must rebuild the whole TOPIC content. Here are the four simple steps:
1. Rebuild the HELP_TEMP_VIEW
CREATE OR REPLACE VIEW HELP_TEMP_VIEW (TOPIC) AS SELECT DISTINCT UPPER(TOPIC) FROM HELP;
2. Delete the TOPICS content
DELETE FROM HELP WHERE TOPIC = 'TOPICS';
3. Rebuild the TOPICS content
INSERT INTO HELP SELECT 'TOPICS', ROWNUM + 10, TOPIC FROM HELP_TEMP_VIEW;
4. Commit your work