DBAsupport.com Forums - Powered by vBulletin
Results 1 to 5 of 5

Thread: Urgent

  1. #1
    Join Date
    Nov 2000
    Posts
    157

    Angry

    Hi Guys

    I have a user database by the name "ONEX" which has the default tablespace "ONEX" and temporary tablespace "TEMP".It has 46 tables, Production database. WIN NT,Oracle 7.3.4.

    Now a user wants to Access this database with only Select privilege on all this 46 tables.

    1.I will create the user account like (Correct me if i am wrong)

    create user <user name> identified by password
    default tablespace onex
    temporary tablespace temp;

    How to grant only select on all the 46 tables to him?

    Please let me know as soon as possible.

    Thanks in Advance
    Ravi
    ravi

  2. #2
    Join Date
    Jun 2000
    Location
    Conway,AR,USA
    Posts
    29
    Step 1
    Create a role as
    CREATE ROLE ROLE1 as
    GRANT SELECT ON table_name[all 46 tables]

    Step 2.
    Assign role to the User You want to have select privilege
    GRANT ROLE1 to USERNAME
    Soumya
    still learning

  3. #3
    Join Date
    Nov 2000
    Posts
    157

    roles

    Hi

    The user will access the databse through sql*net

    he want only the 46 tables of Onex user database(tablespace is onex)

    so i am assigning the default tablespace as onex to him. IS IT CORRECT.Please let me know

    Tahnks
    Ravi
    ravi

  4. #4
    Join Date
    Feb 2000
    Location
    Singapore
    Posts
    1,758
    Assigning the default tablespace is different than grants.

    The objects created by the users are stored in default tablespace but the user can still access the data from other tablespace.

    The right way to do this is, create roll and grant select to the roll assign that roll to user.

    Sanjay

  5. #5
    Join Date
    Dec 2000
    Posts
    3
    1) Create a role with SELECT privilege.
    2) Grant that role to the user.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Click Here to Expand Forum to Full Width