在安裝Oracle 10.2.0.1資料庫時沒有安裝scott/tiger使用者解決辦法

來源:互聯網
上載者:User

在安裝Oracle10.2.0.1資料庫時沒有安裝scott/tiger使用者,如何建立scott使用者和該使用者下的表如下:

可以在$ORACLE_HOME/rdbms/admin/scott.sql 找到此指令碼進行建立,

dlp-> sqlplus /nolog

SQL*Plus: Release 10.2.0.1.0 - Production on Tue May 25 23:53:17 2010

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

SQL> connect sys as sysdba
Enter password:
Connected.
SQL> @$ORACLE_HOME/rdbms/admin/scott.sql
SQL> show user
USER is "SCOTT"
SQL> select table_name from user_tables;

TABLE_NAME
------------------------------
DEPT
EMP
BONUS
SALGRADE

SQL> select * from dept;

    DEPTNO DNAME          LOC
---------- -------------- -------------
        10 ACCOUNTING     NEW YORK
        20 RESEARCH       DALLAS
        30 SALES          CHICAGO
        40 OPERATIONS     BOSTON

建立成功,OK!

相關文章

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.