zoukankan      html  css  js  c++  java
  • scott用户不存在

    用的Oracle版本是12c,在解锁scott时提示用户不存在,于是搜解决方法,给出了两种方法

      一种是加载scott.sql文件(我的scott.sql文件是存在的,在Oracle安装目录下搜索一下),然后在命令行里面输入:“@”+“你刚刚查找到的scott.sql文件的目录”例如:SQL>@E:Oracleproduct12.2.0dbhome_1 dbmsadminscott.sql;说这样scott文件就被加载进来了,然后输入连接命令,如:SQL>conn scott/tiger;这样就可以啦;很遗憾这个方法对我来说不行;下面看第二种方法。

      另一种方法是新建一个scott用户,但是不能用scott这个名字作为新建的用户名,会报错:ORA-65096: 公用用户名或角色名无效;所以用了c##scott这个名字,具体语句如下:

    SQL> create user c##scott identified by tiger;

    用户已创建。

     

    SQL> grant connect,resource,unlimited tablespace to c##scott container = all;

    授权成功。

    SQL> alter user c##scott default tablespace users;

    用户已更改。

    SQL> alter user c##scott temporary tablespace temp;

    用户已更改。

    SQL> connect c##scott/tiger;
    已连接。
    SQL> show user;
    USER 为 "C##SCOTT"

  • 相关阅读:
    第四章:(2)原理之 Dubbo 框架设计
    大三学习进度29
    大三学习进度27
    大三学习进度31
    大三学习进度24
    大三学习进度29
    大三学习进度26
    大三学习进度28
    大三学习进度25
    大三学习进度32
  • 原文地址:https://www.cnblogs.com/w-honey/p/9485888.html
Copyright © 2011-2022 走看看