How to Connect Scott user in Oracle database - SQL Language
In this blog, you will understand if scott user not connect in Oracle.. then how to connect.
In Oracle Scott user does not exist so we have to create
First connect with sys as sysdba user. And the follow the commands as shown in below video.
Commands:-
1. For that go to SQL command line and connect by using username: sys as sysdba ......password: [press enter on keyboard]
2. then create user scott by command "CREATE USER scott IDENTIFIED BY tiger;"
3. Then grant all privileges to scott by command "GRANT ALL PRIVILEGES TO scott;"
4. Then try to connect to scott/tiger and use the command "select * from tab" to see whether the required tables such as EMP table exists or not. *If not then do the step 7* (i.e if it shows "*no rows selected*")
5. Then Download the given file and save it in any suitable drive ( suitably E drive)
6. Then connect to scott/tiger using 'scott' as username and 'tiger' as password.
7. When connected run the command given below line by line (second line may give an error but it is fine)
*second command is most important*
SQL> @ ?/rdbms/admin/scott.sql
SQL> @ ?/sqlplus/demo/demobld.sql
SQL> @ ?/rdbms/admin/utlsampl.sql
After the third command the SQL command line will automatically close
8.- Restart the sql command line:- Connect with Scott and tiger ..
and run query - select * from tab;
Comments
Post a Comment