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

Thread: How to Move Table from one User to another User

Hybrid View

  1. #1
    Join Date
    Nov 2001
    Location
    Delhi
    Posts
    31

    Arrow How to Move Table from one User to another User

    Dear Frineds,

    I want to change owner of table .Is there any alter command for this.
    For exmple:
    Suppose I want EMP table to move from scott to any new user.What will be way to do same apart from export/Import.

    Regards,
    Imti
    Imti
    Junior DBA

  2. #2
    Join Date
    Nov 2002
    Location
    New Delhi, INDIA
    Posts
    1,796
    say king is our new user.

    from scott grant select on emp to king.

    from king do

    create table emp as select * from scott.emp;

    then from scott drop the table emp.

    HTH
    Amar
    "There is a difference between knowing the path and walking the path."

    Amar's Blog  Get Firefox!

  3. #3
    Join Date
    Nov 2001
    Location
    Delhi
    Posts
    31
    Thanks Amar,
    But in such case we can not get constraints/Indexes only table will be created.
    I hope so.
    Imti
    Junior DBA

  4. #4
    Join Date
    Nov 2002
    Location
    New Delhi, INDIA
    Posts
    1,796
    You should ask the whole question, not by parts...

    Well in that case, use exp/imp or tools like toad to get the source.

    HTH
    Amar
    "There is a difference between knowing the path and walking the path."

    Amar's Blog  Get Firefox!

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