How to export a user and their schema from one 10g database to another?

Hi,
I would like to export a user and their entire schema from one 10g database to another one. How do I do this?
thx
adam

If you want to export a user and the schema owned to the user, and import to the same user in a different database, or a different user in the same database, you can use the exp and imp commands as described in the Utilities manual.
These commands are very versatile and have a lot of options - well worth learning properly. To give you a simplistic shortcut, see below - I create a user 'test_move', create some objects in the schema, export, create a new user in the database 'new_move' and import.
oracle@fuzzy:~> sqlplus system/?????
SQL*Plus: Release 10.2.0.1.0 - Production on Sat Mar 11 21:46:54 2006
Copyright (c) 1982, 2005, Oracle.  All rights reserved.
Connected to:
Oracle Database 10g Express Edition Release 10.2.0.1.0 - Production
SQL> create user test_move identified by test_move;
User created.
SQL> grant create session, resource to test_move;
Grant succeeded.
SQL> connect test_move/test_move
Connected.
SQL> create table test (x number);
Table created.
SQL> insert into test values (1);
1 row created.
SQL> exit
Disconnected from Oracle Database 10g Express Edition Release 10.2.0.1.0 - Production
oracle@fuzzy:~> exp system/????? file=exp.dmp owner=test_move
Export: Release 10.2.0.1.0 - Production on Sat Mar 11 21:48:34 2006
Copyright (c) 1982, 2005, Oracle.  All rights reserved.
Connected to: Oracle Database 10g Express Edition Release 10.2.0.1.0 - Production
Export done in AL32UTF8 character set and AL16UTF16 NCHAR character set
About to export specified users ...
. exporting pre-schema procedural objects and actions
. exporting foreign function library names for user TEST_MOVE
. exporting PUBLIC type synonyms
. exporting private type synonyms
. exporting object type definitions for user TEST_MOVE
About to export TEST_MOVE's objects ...
. exporting database links
. exporting sequence numbers
. exporting cluster definitions
. about to export TEST_MOVE's tables via Conventional Path ...
. . exporting table                           TEST          1 rows exported
. exporting synonyms
. exporting views
. exporting stored procedures
. exporting operators
. exporting referential integrity constraints
. exporting triggers
. exporting indextypes
. exporting bitmap, functional and extensible indexes
. exporting posttables actions
. exporting materialized views
. exporting snapshot logs
. exporting job queues
. exporting refresh groups and children
. exporting dimensions
. exporting post-schema procedural objects and actions
. exporting statistics
Export terminated successfully without warnings.
oracle@fuzzy:~> sqlplus system/?????
SQL*Plus: Release 10.2.0.1.0 - Production on Sat Mar 11 21:49:23 2006
Copyright (c) 1982, 2005, Oracle.  All rights reserved.
Connected to:
Oracle Database 10g Express Edition Release 10.2.0.1.0 - Production
SQL> create user new_move identified by new_move;
User created.
SQL> grant create session, resource to new_move;
Grant succeeded.
SQL> exit
Disconnected from Oracle Database 10g Express Edition Release 10.2.0.1.0 - Production
oracle@fuzzy:~> imp system/????? file=exp.dmp fromuser=test_move touser=new_move
Import: Release 10.2.0.1.0 - Production on Sat Mar 11 21:50:12 2006
Copyright (c) 1982, 2005, Oracle.  All rights reserved.
Connected to: Oracle Database 10g Express Edition Release 10.2.0.1.0 - Production
Export file created by EXPORT:V10.02.01 via conventional path
import done in AL32UTF8 character set and AL16UTF16 NCHAR character set
. importing TEST_MOVE's objects into NEW_MOVE
. . importing table                         "TEST"          1 rows imported
Import terminated successfully without warnings.
oracle@fuzzy:~>                                                       If moving between databases, remember to set the SID properly before the import. If keeping the same userid, skip the from/to stuff in the import.
There are many variations on the theme ...
You can simplify this. You can select tables individually. You can use a parameter file. You can transport all the constraints and data. You can skip the data and only move the definitions. You can get some help (imp/exp help=yes).
And, if it's all 10g, there is a new and improved facility called expdp/impdp (dp = data pump) which has a lot more capability as well, including direct transfer (no intermediate file) together with suspend/restart. Also documented in the Utilities manual.

Similar Messages

  • HT204053 how do i move page and numbers documents from one icloud login to another?

    how do i move page and numbers documents from one icloud login to another?
    I had to change my email address whcih meant new apple login.
    I have a number of docs in iwork/pages and iwork/numbers.  How do I transfer them to my new login?

    There's a couple of ways but my tip backing up your documents in the cloud is as good as any.

  • How do you transfer contacts and other info from one gmail address to another?

    Somebody screwed up my gmail so I created another account which does synch with my android phone which the other does not. But I lost all my contacts from the phone. The contacts still exist but they are on the old gmail account which does not synch with my cellphone. How do I transfer my addresses and phone numbers from one gmail address to another?

    That is a question for Gmail support.
    https://support.google.com/mail/?hl=en

  • I have 2 Macs - an iMac that holds my entire iPhoto library and a Mac Book Pro that I use to hold a subset of the main library - how can I transfer photos and their metadata from the main library of the iMac to my Mac Book?

    I have 2 Macs - an iMac which holds my main iPhoto library and a Mac Book Pro which holds a subset of the library. How can I transfer photos and their metadata from the main library to the smaller 1 on the Mac Book Pro?

    Link the two Macs together and use iPhoto Library Manager
    Regards
    TD

  • HT2518 how do i or can i drag and drop files from one external drive to another ???HOW

    how do i drag and drop files from one external drive to another, i cannt get both drives to open up. only one at a time.. i have alot to learn i know but that is where i am at the time...

    You posted here so would assume you are also talking about running Windows.
    Are the drives NTFS and use on Windows?
    Are they Mac HFS formatted?
    You likely will need NTFS for OS X in one case. to mount PC and use under Mac OS Lion
    MacDrive to mount and WRITE to HFS drives under Windows

  • How can I copy a time machine backup from one Time Capsule to another ?

    How can I copy a time machine backup from one Time Capsule to another ? I bought a 1 Tb Time Capsule to replace my 512Mb Time Capsule. Now, I like to copy my time machine backup from the old Time Capsule to the new one so I can keep using my backup.

    from this support article: 
    (click on image to enlarge)

  • I am having problems copying and pasting clips from one project timeline to another. When I do this they often alter in length. Sometimes by two frames. Other times they lose a chunk off the end of the last clip in the sequence. Has anyone else found

    I am having problems copying and pasting clips from one project timeline to another. When I do this they often alter in length. Sometimes by two frames. Other times they lose a chunk off the end of the last clip in the sequence. Has anyone else found this?

    You need to give a lot more information about the media specifications and the project properties you're using in the different projects.

  • Import all users and their objects without doing full database import

    Hi Guys,
    I have a task to that involves Importing all existing users and their objects in production to the test database without doing a full database import - Please how do i do this?
    Pls i need your help urgently.

    SQL> select * from v$version;
    BANNER
    Oracle Database 10g Express Edition Release 10.2.0.1.0 - Product
    PL/SQL Release 10.2.0.1.0 - Production
    CORE 10.2.0.1.0 Production
    TNS for Linux: Version 10.2.0.1.0 - Production
    NLSRTL Version 10.2.0.1.0 - Production
    I tried to import objects and data from a user from a FULL dump file. File was created with the following command:
    server is: SQL*Plus: Release 10.2.0.1.0 - Production on Wed May 26 15:34:05 2010
    exp full=y FILE="full.dmp" log=full.log
    Now I imported:
    imp file=full.dmp log=full.log INCTYPE=SYSTEM
    imp fromuser=user1 file=full.dmp
    Results: not all the user procedures have been imported:
    SQL> select count(*) from user_procedures;
    the Original
    COUNT(*)
    134
    the current:
    select count(*) from user_procedures;
    COUNT(*)
    18
    I also tried these alternatives:
    exp tablespaces="user1_data" FILE="user1.dmp" log=user1.log
    exp LOG=user1.log TABLESPACES=user1_data FILE=user1_data.dmp
    exp LOG=user1owner.log owner=user1 FILE=user1owner.dmp
    expdp DIRECTORY=dpump_dir1 dumpfile=servdata_pump version=compatible SCHEMAS=user1
    impdp directory=data_pump_dir dumpfile=servdata_pump.dmp :
    ORA-39213: Metadata processing is not available
    SQL> execute dbms_metadata_util.load_stylesheets
    BEGIN dbms_metadata_util.load_stylesheets; END;
    ERROR at line 1:
    ORA-31609: error loading file "kualter.xsl" from file system directory
    "/usr/lib/oracle/xe/app/oracle/product/10.2.0/server/rdbms/xml/xsl"
    ORA-06512: at "SYS.DBMS_METADATA_UTIL", line 1793
    ORA-06512: at line 1
    file kualter.xsl does not exist in XE !!
    imp owner=user1 rows=n ignore=y
    imp full=y file=user1_data.dmp
    imp full=y file=full.dmp tablespaces=user1_data,user1_index rows=n ignore=y
    So, I do not understand why user1 objects are not imported:
    see this part of the first import log:
    Export file created by EXPORT:V10.02.01 via conventional path
    import done in US7ASCII character set and AL16UTF16 NCHAR character set
    import server uses WE8ISO8859P1 character set (possible charset conversion)
    . importing SYS's objects into SYS
    . importing USER1's objects into USER1
    . . importing table .........................
    why only 18 rows?
    if you have an suggestion, you are welcome, as I do not have any other idea...
    ren
    Edited by: ronpetitpatapon on May 26, 2010 12:38 PM
    Edited by: ronpetitpatapon on May 26, 2010 12:41 PM
    Edited by: ronpetitpatapon on May 26, 2010 1:03 PM

  • HT2688 How can I "click and drag" songs from one shared library to another?

    I have home sharing activated on my mom's computer and mine and before the newest version of itunes, we were able to click and drag songs from one users' library into the other. We are not able to do that now and I wanted to know if there was a way to do this in the newest version of itunes.

    I am using a Windows computer first off, not sure if that makes a difference,  When you say "click import" where is import.  I can not find anything that says "import" to click.

  • How to pass a "object" as a prameter from one java class to another java

    hi experts, I want to know "How to pass and get object as a parameter from one java class to another java class". I tried follwoing code just check it and give suggetions..
    import Budget.src.qrybean;
    public class ConfirmBillPDF extends HttpServlet
    qrybean db = new qrybean();
    SimplePDFTable pdfTable = new SimplePDFTable();
    pdfTable.simplePDFTableShow("2010","2011","1","2","1","131","102");
    }Here i want to pass db with simplePDFTableShow method. simplePDFTableShow is in another java class. So how can i do this.
    And also i want to know, how this obj will get.
    please help me.
    Edited by: andy_surya on Jul 14, 2010 7:51 AM

    Hi andy_surya
    what is this i am not understand
    pdfTable.simplePDFTableShow("2010","2011","1","2","1","131","102");but i am try to solve your problem try this
    qrybean db = new qrybean();
    SimplePDFTable pdfTable = new SimplePDFTable();
    pdfTable.simplePDFTableShow(db);and access like this in SimplePDFtable class update your method
    simplePDFTable(qrybean tempDB)
    // write your code
    }

  • Proper way to migrate schema from one DS5.2 to another

    What is the best error free way to migrate schema from one Directory Server 5.2 to another.
    Thanks,

    I have migrated schema from 5.1 to 5.2 and below are my experiences. Check if this helps you in any way.
    - After overwriting 99user.ldif from 5.1 to 5.2; experienced problems in starting the DS 5.2 instance. On looking into the logs, few object classes and attributes gave problems.
    - Modified 99user.ldif in DS 5.2 by appending schema values group by group. Able to start DS 5.2 instance without problems
    - Migrated data (ldif file) via ldif2db command to DS 5.2
    - Encountered problems in DS 5.2; Suffix got dissappeared after migrating the data and a restart of DS 5.2 instance. Upon looking logs and few troubleshooting steps, found the aci's in the data file creating problems
    - Removed aci's in data (ldif file) manually and migrated using ldapmodify command and it worked

  • How do i change the redeem gift card from one apple id to another?

    i want to move the redeem gift card from one apple id to another one is that possible?

    Only if the Card is complete and has not been used.
    Contact iTunes Customer Service and request assistance
    Use this Link  >  Apple  Support  iTunes Store  Contact

  • Quick question about exporting email address and their alias from Exchange 2007 mailbox

    Hi Everyone,
    We have Exchange 2007 and 2013 servers. All users are still 2007 servers. I have a list of users around 179 out of 3000 in a CSV file. I would like to export those 179 users primary smtp and their aliases. Is it possible to achieve through any script?
    Thanks in advance.
    Regards,
    Siva

    Hello Siva,
    You don't need a script for this. Information can be obtained with simple command.
    $AllUsers = Get-Mailbox -ResultSize Unlimited | Select DisplayName,Alias,PrimarySMTPAddress,SamACcountName,Database,LegacyExchangeDN
    $AllUsers | Export-Csv Outputfile.csv -NoTypeInformation
    Try this and let me know if it helps!
    if you want PrimarySMTPAddress and alias of only those users whose information on the excel sheet, then what do you have as the column name in the excel sheet which you are using to query on the server.
    Considering that you are using Alias to query the server to get the details you can try below:
    $Global:Output = @()
    $CsvData = Import-Csv Inputfile.csv
    foreach($line in $CsvData)
    {$CurrentObject = $Line.AliasWrite-Host “Processing Obect “$CurrentObject “From Csv File”
    –ForeGroundColor YELLOW$EmailIDJoin = ""$EmailAddresses = @()$UserInfo = "" | Select DisplayName,PrimarySMTPAddress,Alias,SamAccountName,Database,LegacyExchangeDN,EmailAddresses
    $UserInfo.DisplayName = (Get-Mailbox $CurrentObject).DisplayName
    $UserInfo.PrimarySMTPAddress = (Get-Mailbox $CurrentObject).PrimarySMTPAddress
    $UserInfo.Alias = (Get-Mailbox $CurrentObject).Alias
    $UserInfo.SamAccountName = (Get-Mailbox $CurrentObject).SamAccountName
    $UserInfo.Database = (Get-Mailbox $CurrentObject).Database
    $UserInfo.LegacyExchangeDN = (Get-Mailbox $CurrentObject).LegacyExchangeDN
    $EmailAddresses = (Get-Mailbox $CurrentObject)|%{$_.EmailAddresses}
    for($i=0;$i -lt $EmailAddresses.Count;$i++)
    $EmailIDJoin += $EmailAddresses[$i].ProxyAddressString
    if($i -lt $EmailAddresses.Count - 1)
    $EmailIDJoin += ','
    $UserInfo.EmailAddresses = $EmailIdJoin
    $Global:Output += $UserInfo
    #Export output to CSV File
    $Global:Output | Export-Csv GlobalOutput.csv -NoTypeInformation

  • Is there a way to export photo images and their metadata from Adobe Bridge to MS excel?

    Is there a plugin, or script that allows photos and their metadata to be exported from Adobe Bridge to Microsoft excel?

    I would like to see the description with the image when it is attached to an email.  I would also like to be able to create a DVD of the images that would include the descriptions when the DVD is played back.
    For that you will need iDVD to create a slideshow of the images and then display either the Title, Description or both as shown below and then burn to disk creating a video DVD to play on a TV set:
    If you want the description on the image itself you'll need to use a 3rd party editor like one of those below or the free watermark iPhoto plugin, BorderFX.
    Some Image Editors That Support layers:
    Photoshop Elements 11 for Mac - $79
    GraphicConverter - $40
    Rainbow Painter - $30
    Imagerie - $38
    Acorn - $50
    Pixelmator - $60
    Seashore - Free
    GIMP for Mac - Free
    Xee 2.1 - free

  • How to get the user and groups information from http header

    Hi All,
    In my current scneario, we are using Siteminder for SSO setup.. And in this process, after authentication and authorization, they are going to append the user information and group information of the user into a HTTP header and it will be sent back to our presentation services.. We have to extract the user information and group information from the http header.
    My HTTP header will look like as follows..
    SM_USER XYZ
    SM_USERDN CN=Firstname\, Lastname\, xyz, OU=GPO-Low Level Security,OU=Domain Users,OU=BU FDT,
    SM_USERGROUPS CN=GG-CA-SiteminderAdmins, OU=Global,OU=Domain Groups, DC=com^CN=GG-ServiceDeskAdmin-TCCORPCEFS
    And also if anyone explain me the overall working of SSO in detail like how presentation services will make a connection to BI server( I guess using Impersonator User), and also how our BI server will read the URL from presentation services and the over all working flow in our OBIEE..
    Thanks a lot....

    Please use the search! this topic has come up lots of times already.

Maybe you are looking for