1. Get rid of all advertisements and get unlimited access to documents by upgrading to Premium Membership. Upgrade to Premium Now and also get a Premium Badge!

SCOTT/Tiger User does not exist in 11g

Discussion in 'SQL PL/SQL' started by mohammad shahzad, Oct 21, 2011.

  1. felows
    i have installed oracle 9i and i have viewed sql *plus. when i enter the scott/tiger as user/password, it not except.
    plz help
     
  2. zargon

    zargon Community Moderator Forum Guru

    Messages:
    2,346
    Likes Received:
    347
    Trophy Points:
    1,430
    Location:
    Aurora, CO
    Re: sql * plus problem

    The account is no longer created by default in releases 9 and later. You will need to create it if you want to use it.
     
  3. refrigerantcomp

    refrigerantcomp Active Member

    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    55
    Re: sql * plus problem

    So, if that is the case...we need to create a new account again?
     
  4. zargon

    zargon Community Moderator Forum Guru

    Messages:
    2,346
    Likes Received:
    347
    Trophy Points:
    1,430
    Location:
    Aurora, CO
    Re: sql * plus problem

    Yes, as i said in my prior response:

    Code (SQL):
     
    SQL> CREATE USER scott IDENTIFIED BY tiger;
     
    USER created.
     
    SQL> GRANT CONNECT TO scott;
     
    GRANT succeeded.
     
    SQL>
     
    You cannot connect using an account which does not exist in the database.
     
  5. kiran.marla

    kiran.marla Forum Genius

    Messages:
    403
    Likes Received:
    52
    Trophy Points:
    505
    Location:
    Khammam
    Re: sql * plus problem

    May be you have entered wrong password. Scott User is continued in 11g also. Check it with correct password or else go system/manager and change the password with the following sql command.

    Code (SQL):
    ALTER USER scott IDENTIFIED BY tiger;
     
  6. zargon

    zargon Community Moderator Forum Guru

    Messages:
    2,346
    Likes Received:
    347
    Trophy Points:
    1,430
    Location:
    Aurora, CO
    Re: sql * plus problem

    Not by default:

    Code (SQL):
    SQL*Plus: Release 11.2.0.2.0 Production ON Sun Oct 23 22:56:18 2011
    Copyright (c) 1982, 2010, Oracle.  ALL rights reserved.

    Connected TO:
    Oracle DATABASE 11g Enterprise Edition Release 11.2.0.2.0 - 64bit Production
    WITH the Partitioning, Automatic Storage Management, OLAP, DATA Mining
    AND REAL Application Testing options

    SQL> SELECT username, account_status FROM dba_users;
     
    USERNAME                       ACCOUNT_STATUS
    ------------------------------ --------------------------------
    SYS                            OPEN
    SYSTEM                         OPEN
    OUTLN                          EXPIRED & LOCKED
    APPQOSSYS                      EXPIRED & LOCKED
    ANONYMOUS                      EXPIRED & LOCKED
    DBSNMP                         EXPIRED & LOCKED
    WMSYS                          EXPIRED & LOCKED
    XDB                            EXPIRED & LOCKED
    XS$NULL                        EXPIRED & LOCKED
    DIP                            EXPIRED & LOCKED
    ORACLE_OCM                     EXPIRED & LOCKED
     
    11 ROWS selected.
     
    SQL>
    Possibly if a sample database is created with one of the provided templates SCOTT exists; it is not created if only the software is installed or if a custom database is created.
     
  7. kiran.marla

    kiran.marla Forum Genius

    Messages:
    403
    Likes Received:
    52
    Trophy Points:
    505
    Location:
    Khammam
    Re: sql * plus problem

    Code (SQL):
    SQL*Plus: Release 9.0.1.4.0 - Production ON Mon Oct 24 12:10:12 2011

    (c) Copyright 2001 Oracle Corporation.  ALL rights reserved.


    Connected TO:
    Oracle DATABASE 11g Enterprise Edition Release 11.1.0.7.0 - Production
    WITH the Partitioning, OLAP, DATA Mining AND REAL Application Testing options

     



      1* SELECT USERNAME, ACCOUNT_STATUS FROM DBA_USERS WHERE USERNAME = 'SCOTT'
    SQL> /

    USERNAME                       ACCOUNT_STATUS
    ------------------------------ --------------------------------
    SCOTT                          OPEN

    SQL>

    Hmmm .. May be so. But In my company it was existing.
     
  8. zargon

    zargon Community Moderator Forum Guru

    Messages:
    2,346
    Likes Received:
    347
    Trophy Points:
    1,430
    Location:
    Aurora, CO
    Re: sql * plus problem

    Which may have occurred during an upgrade to 11g from a prior release of Oracle, or from a full import of an older release into 11g. Again, I have created numerous 11g databases and do not have SCOTT created. If you have it does not automatically imply that it was created by the 11g install/database creation.
     
  9. rajavu

    rajavu Forum Guru

    Messages:
    815
    Likes Received:
    52
    Trophy Points:
    610
    Location:
    @ Bangalore , India
    You can recreate SCOTT schema just by running the utlsampl.sql from the following directory

     
  10. rajavu

    rajavu Forum Guru

    Messages:
    815
    Likes Received:
    52
    Trophy Points:
    610
    Location:
    @ Bangalore , India
    Don't forget to run the script from SYS user.
     
  11. ssankars

    ssankars Premium Member

    Messages:
    32
    Likes Received:
    1
    Trophy Points:
    110
    Location:
    Hyderabad
    Hi Mohammad,

    Are you using Scott scema for the first time after installing Oracle 9i. If yes then there may be chance that this account will lock for first time and you have to unlock it first. Then after you can use it.
     
  12. zargon

    zargon Community Moderator Forum Guru

    Messages:
    2,346
    Likes Received:
    347
    Trophy Points:
    1,430
    Location:
    Aurora, CO
    Please read the thread topic as it clearly states this is in 11g.