在linux系统中,只要遇到不懂的,都可以问man(俗称的男人)。
没有男人不懂的,只有男人你问不出的。
而在oracle中,没有man,不过,它却有help。
安装完oracle 10g后,默认是有help,但是它还不够强大,不暴力,不男人。
SYS > help index
Enter Help [topic] for help.
@ COPY PAUSE SHUTDOWN
@@ DEFINE PRINT SPOOL
/ DEL PROMPT SQLPLUS
ACCEPT DESCRIBE QUIT START
APPEND DISCONNECT RECOVER STARTUP
ARCHIVE LOG EDIT REMARK STORE
ATTRIBUTE EXECUTE REPFOOTER TIMING
BREAK EXIT REPHEADER TTITLE
BTITLE GET RESERVED WORDS (SQL) UNDEFINE
CHANGE HELP RESERVED WORDS (PL/SQL) VARIABLE
CLEAR HOST RUN WHENEVER OSERROR
COLUMN INPUT SAVE WHENEVER SQLERROR
COMPUTE LIST SET
CONNECT PASSWORD SHOW
SYS > select count(*) from system.help;
COUNT(*)
----------
978
既然oracle自己软了下来,那我们就得要让它硬起来,像男人点,让它变得很黄很暴力。
我们自己给它打造装备。
Installing the Help Facility Manually
The Help Facility may be installed manually using the shell script
$ORACLE_HOME/bin/helpins. Before you run the script, the SYSTEM_PASS environment variable should be set to the SYSTEM schema name and password. For example:
$ setenv SYSTEM_PASS SYSTEM/MANAGER
$ helpins
If the SYSTEM_PASS variable is not set, helpins prompts you for the SYSTEM password and loads the help data into the SYSTEM schema. You can also run $ORACLE_HOME/sqlplus/help/helpbld.sql helpus.sql to install the Help Facility. The system user can run the file helpbld.sql and its argument, helpus.sql, in SQL*Plus to create Help Facility Tables. For example:
$ sqlplus system/manager
SQL> @?/sqlplus/admin/help/helpbld.sql helpus.sql
注意,这里必须是system用户,我的做法如下。
$sqlplus system/oracle
SYSTEM > @?/sqlplus/admin/help/help.sql
SYS > select count(*) from system.help;
COUNT(*)
----------
5335
SYS > help alter user;
ALTER USER
----------
Use this command to change any of the following characteristics of a
database user:
* authentication mechanism of the user
* password
* default tablespace for object creation
* tablespace for temporary segments created for the user
* tablespace access and tablespace quotas
* limits on database resources
* default roles
ALTER USER user
{ IDENTIFIED {BY password | EXTERNALLY
| GLOBALLY AS 'CN=user'}
| DEFAULT TABLESPACE tablespace
| TEMPORARY TABLESPACE tablespace
| QUOTA { integer [K | M] | UNLIMITED} ON tablespace
[ QUOTA { integer [K | M] | UNLIMITED} ON tablespace] ...
总结一下,这个help.sql是dba的必备杀器。这可是传说中的套装。
附件我已上传,是help.jpg,大家只要把格式改成sql就行了。
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/23203417/viewspace-625700/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/23203417/viewspace-625700/