Hi all,
Here's my issue:
I created a a table called "TEST" with user student. The user student has the following tablespace:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
USERNAME CREATED PROFILE DEFAULT_TABLESPACE TEMPORARY_TABLESPACE
student 22-JUL-08 DEFAULT USERS TEMP
teacher 22-JUL-08 DEFAULT USERS TEMP
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
So, the the table "TEST" is in the table_space USERS as shown below:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
SEGMENT_NAME TABLESPACE_NAME
TEST USERS
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
So when I logged in as another user, let's say, "teacher" which has the same tablespace as the user "student", and try to do a desc or select on the table "TEST". I got the following error message.
SQL> select * from TEST;
select * from TEST
*
ERROR at line 1:
ORA-00942: table or view does not exist
I did a search on the the erro message and I found the link below.
In this link it requires the user "student" to create a role and basically create some kind of table student.TEST. Then, grant a right on this table to user "teacher". So, the user "teacher" will be able to access the "TEST" table as follows:
select * from student.TEST;
So, my question is:
Is there any other way so that the user "teacher" can access the table(s) created by the user "student" directly? For instance,
select * from TEST;
Thank you in advance for your help.
Have a great day!
babe1898
Here's my issue:
I created a a table called "TEST" with user student. The user student has the following tablespace:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
USERNAME CREATED PROFILE DEFAULT_TABLESPACE TEMPORARY_TABLESPACE
student 22-JUL-08 DEFAULT USERS TEMP
teacher 22-JUL-08 DEFAULT USERS TEMP
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
So, the the table "TEST" is in the table_space USERS as shown below:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
SEGMENT_NAME TABLESPACE_NAME
TEST USERS
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
So when I logged in as another user, let's say, "teacher" which has the same tablespace as the user "student", and try to do a desc or select on the table "TEST". I got the following error message.
SQL> select * from TEST;
select * from TEST
*
ERROR at line 1:
ORA-00942: table or view does not exist
I did a search on the the erro message and I found the link below.
In this link it requires the user "student" to create a role and basically create some kind of table student.TEST. Then, grant a right on this table to user "teacher". So, the user "teacher" will be able to access the "TEST" table as follows:
select * from student.TEST;
So, my question is:
Is there any other way so that the user "teacher" can access the table(s) created by the user "student" directly? For instance,
select * from TEST;
Thank you in advance for your help.
Have a great day!
babe1898