Efficient way to copy business data from Production DB to Test DB

Hi.
I'm a DBA in a software dev company.
The testing team people ask me replicate a customer (and all its data) from the System-Test DB to a DB of a certain tester.
Problem is the CUSTOMER table has releations to 6 other tables (ORDERS, ORDER_ITEMS, CONTACTS, etc) which in turn has relations to other tables.
As I see it I have two options:
1. Copy the entire System Tests DB to the other DB. This is bad - this DB is very large and we don't have enough disk space.
2. Work out manually all the relations of the CUSTOMER and write a script to copy just the relevant tables/records for the specific customer. This seems too much work...
Anybody familiar with a script/tool to perform this?

Ok.. I gave this tool a test run. Pretty impressive.
It allows you to set a 'root' entity (Customer in my case) and then it calculates all the relations by reading my schema's foreign-keys. I have one table that is logically connected, but has no FK defined in my schema. No problem - I can add this relation manually.
Now, I need to set the WHERE on my root entity (e.g. CUSTOMER_ID = 1234567) and the tool just shows me all the relevant tables with only the appropriate records displayed. Charm!
Lastly, I copied the tables/record to my test DB (the tool has a 'Sync' window).
Mission accomplished.

Similar Messages

  • What is the best way to mimic the data from production to other server?

    Hi,
    here we user streams and advanced replication to send the data for 90% of tables from production to another production database server. if one goes down can use another one. is there any other best option rather using the streams and replication? we are having lot of problems with streams these days they keep break and get calls.
    I heard about data guard but dont know what is use of it? please advice the best way to replicate the data.
    Thanks a lot.....

    RAC, Data Guard. The first one is active-active, that is, you have two or more nodes accessing the same database on shared storage and you get both HA and load balancing. The second is active-passive (unless you're on 11.2 with Active Standby or Snapshot Standby), that is one database is primary and the other is standby, which you normally cannot query or modify, but to which you can quickly switch in case primary fails. There's also Logical Standby - it's based on Streams and generally looks like what you seem to be using now (sort of.) But it definitely has issues. You can also take a look at GoldenGate or SharePlex.

  • Best way to copy ALL DATA from song to song?

    Hello everyone,
    I'm in the middle of scoring a film and have ran into what seems to be a corrupted song, and want to attempt to transfer all data from this song into a new file.
    I'm running multiple global tracks with changes in tempos and time sigs all over, multiple audio tracks, and various Virtual instruments. I also have an extensive environment in which I use instrument tracks to access my exs instruments, as well as multi-instrument tracks for kontakt 2. Of course I have this saved as a template, but as you know as projects progress, the current song rarely looks like your autoload. So simply copying and pasting will not work, as I have many new instruments and audio files in different places in my arrange page. Thus when I try to copy and paste, logic sees that the current tracks are not "correct" and asks to "create new instruments" which seems to randomly throw all the instruments to the bottom of my arrange page, making it all out of whack!
    With some help from the audio config window and some manual editing of the arrange page, I was able to get my song pretty much back to normal, but for future reference, what is the best way to transfer all of my data to another song, while still keeping the look and functionality of the song intact?
    Thanks in advance for your help! If it helps to see what I'm talking about, I'm willing to post my song file for reference, just ask.

    I'd LOVE to somehow avoid #4 if possible. As I stated
    above, my projects always change from the templates
    due to extra audio tracks, audio instruments, etc, so
    a simple "copy and paste" does not seem to work.
    Is there something I'm missing?
    Yup, I was missing something really simple. If you choose NOT to copy instruments, it will ask you to keep the instrument or create a new track. If you keep the instrument (since my instruments names remained the same as the template) logic will connect the tracks with the instruments and only put the additional tracks (i.e. extra audio tracks etc) on the bottom. WAY COOL!
    Now my process is a little easier, however if you have any other tips so share please feel free to post.

  • Exporting data from Production to Development in a R/3 System

    Good Morning,
    I have a landscape where i have a Productive and a Development system (SAP R/3 Enterprise Release 4.70 SR1 1.10 with MaxDB 7.5 running on a HP-UX 11.23) and i was asked to copy the data and customizing (not user master data) from Production to Development. Both systems have 7 clients (6 for each country and one for Human Resources) and i need to copy the productive data to the development data (the Productive data can overwrite the Development data).
    This is my first time doing this, and since i have a short deadline to do it, i need all the help i can get...
    I'm not sure if i should use SCC8 or SCC9 in order to create a transport request for each client copy.
    I've checked the OS space in sapdata and transport directories, i've also checked the database space and i need to change MAXDATAVOLUMES size and also create more volumes.
    Now that i've done that, i need to know what to do next... Does anyone knows where i can find a procedure or documentation on this? Some kind of step by step guide?
    About the Export Profiles, which default profile should i choose in order to copy
    All client specific data, customizing AND NOT user master data?
    Can i do any kind of test run before the export in order to understand the space i'm going to need in transport directory for example?
    Thanks in advance.
    Best Regards,
    Pedro Gaspar

    Hello Pedro,
    1. In SCC8 the SAP_APPL profile isn't available, so i guess i need to use SAP_ALL and change the user master data accordingly afterwards right?
    In that case, you should/can 'Export' the user master of the target system before the Client copy, so that you can re-import the same user master in the target system after sap_all copy from source.
    2. I also have several project teams developing in ABAP in my development system. If i export the productive client, will the ABAP code be overwritten (scripts, smartforms, etc...)? I ask this, because right now there are several programs with different versions in both systems (the landscape consists of only a DEV and PRD system NO quality). If the ABAP code in development will be overwritten, i need to tell the development teams to comment all the changes, then create transports to production to make the program versions the same, and then save the data an cofiles to import them again in development after the import. Will also RFC definitions change? Jobs will also be copied? What's the difference between this and a Homogeneous System Copy using backup/restore?
    This is the reason that normally the 'Production to Development' copy is not recommended. I would wait if our other techies here can help/advise us for this.
    A simple difference between a client copy and system copy is that the client copy is just 'client dependent' change and system copy is 'system wide' change - erasing everything on the target and just overwriting/duplicating the 'complete source' onto the target.
    Thanks

  • I am moving from PC to Mac.  My PC has two internal drives and I have a 3Tb external.  What is best way to move the data from the internal drives to Mac and the best way to make the external drive read write without losing data

    I am moving from PC to Mac.  My PC has two internal drives and I have a 3Tb external.  What is best way to move the data from the internal drives to Mac and the best way to make the external drive read write without losing data

    Paragon even has non-destriuctive conversion utility if you do want to change drive.
    Hard to imagine using 3TB that isn't NTFS. Mac uses GPT for default partition type as well as HFS+
    www.paragon-software.com
    Some general Apple Help www.apple.com/support/
    Also,
    Mac OS X Help
    http://www.apple.com/support/macbasics/
    Isolating Issues in Mac OS
    http://support.apple.com/kb/TS1388
    https://www.apple.com/support/osx/
    https://www.apple.com/support/quickassist/
    http://www.apple.com/support/mac101/help/
    http://www.apple.com/support/mac101/tour/
    Get Help with your Product
    http://docs.info.apple.com/article.html?artnum=304725
    Apple Mac App Store
    https://discussions.apple.com/community/mac_app_store/using_mac_apple_store
    How to Buy Mac OS X Mountain Lion/Lion
    http://www.apple.com/osx/how-to-upgrade/
    TimeMachine 101
    https://support.apple.com/kb/HT1427
    http://www.apple.com/support/timemachine
    Mac OS X Community
    https://discussions.apple.com/community/mac_os

  • How to copy the Data From Oracle Table To SAP Table

    Hi Friends,
    We need to copy the data from Oracle Database Table to SAP Table. The data should be updated simultaneously in both tables . Should I write a program that contains the native sql statement like EXEC SQL PERFORMING WRITE,....
    I appreciate any suggestions regarding this.
    Regards
    CSM Reddy

    Hi,
    since you posted this question in the DB2 forum I assume that you are using a DB2 database for your SAP system.
    To access a table from a legacy ORACLE database you may use the DBSL multiconnect feature. I.e. you open a secondary connecction in the SAP system to your ORALE database. You can then ready the data from the ORACLE database into an ABAP internal table and insert it afterwards into the DB2 table on the main connection.
    Another way to access an ORACLE table from a DB2 database is to use the DB2 federated database feature. This requires a little bit more DB2 skill. With this feature you can make the ORACLE table visible within the DB2 database. To copy data you can then simply use a "INSERT ... SELECT" statement. 
    Regards
             Frank

  • Best Way to port the data from one DB to another DB using Biztalk

    Hi,
    please suggest best way to move the data from one db to another DB using biztalk.
    Currently I am doing like that, for each transaction(getting from different source tables) through receive port, and do some mapping (some custom logic for data mapping), then insert to target normalized tables(multiple tables) and back to update the status
    of transaction in source table in sourceDB. It is processing one by one.
    How/best we we can do it using  bulk transfer and update the status. Since it has more than 10000 transaction per call.
    Thanks,
    Vinoth

    Hi Vinoth,
    For SQL Bulk inserts you can always use SQL Bulk Load
    adapter.
    http://www.biztalkgurus.com/biztalk_server/biztalk_blogs/b/biztalksyn/archive/2005/10/23/processing-a-large-flat-file-message-with-biztalk-and-the-sqlbulkinsert-adapter.aspx
    However, even though a SQL Bulk Load adapter can efficiently insert a large amount of data into SQL you are still stuck with the issues of transmitting the
    MessageBox database and the memory issues of dealing with really large messages.
    I would personally suggest you to use SSIS, as you have mentioned that records have to be processed in specific time of day as opposed to when the
    records are available.
    Please refer to this link to get more information about SSIS: http://msdn.microsoft.com/en-us/library/ms141026.aspx
    If you have any more questions related to SSIS, please ask it in
    SSIS 
    forum and you will get specific support.
    Rachit

  • What is te best way to copy a table from a database to another?

    Hello friends:
    I have two databases: an Access database and an Oracle database. I must copy the data from al tables from the Access database to the oracle database. The tables in the both databases are equal (number of columns, type, etc).
    I read an resultset from acces (select * from table1) and I insert every row in the Oracle database with an while loop (while (r.next)...). It works fine when there are a few rows, but I have a table with over 200000 rows, and when I'm copying the row number 30.000, the system goes very slow...
    How can I copy tables from a database to another more quickly?
    Thanks!

    CASE #1
    The most efficient method would be to copy all the rows from Microsoft Access and write them to a text file using Access's native interface (not JDBC), then use Oracle's SQL Loader utility (not JDBC) to insert the data.
    You can insert 200,000 rows of 80 bytes each in 30 seconds or less even on a modest Oracle system using SQL Loader. The extract from Access is very dependent on the size of the CPU and the available memory.
    Hint 1: Avoid explicit or implict network traffic.
    Hint 2: Extract and load from local drives rather than networked or shared drives on other services
    Please note that this is done for efficiency of load, but has issues related to error checking, and operational scripting.
    Anything else you do or use will be slower than the method (above).
    CASE #2
    If you want to integrate this into a single JDBC program which will provide better operational management of the process, then you can simply connect to both databases in your Java program, then read the rows one at a time from Access, insert them using the Batch mechanism of JDBC to Oracle. You will also want to set the FetchSize in Oracle to a larger value then the default (i.e set it to 100 vs 10).
    Hint #3 You may want to look into alternative JDBC drivers for accessing MS Access, rather than the JDBC-ODBC bridge which is not optimized for MS Access. You may also want to consider using the OCI8 driver from Oracle rather than the thin driver. Both provide Type 4 functionality but I have heard (not experienced) that the OCI8 driver is better for managing batch style of processing like yours
    Good luck!
    Joel

  • Copy the data from one column to another column using @

    I have two columns here - A and B.
    Column A has a complicated formula that will generate results. I wanted the results in Column A to be reflected in Column B without pasting the A's formula in B. This will save me the trouble of editing formulas in more than 1 column if there is a need.
    I saw somewhere that you can use "@" in column B but I have no idea how to use it.
    Assumingly column A is the first column. I tried to insert '@1' in B's formula and change B's column properties' Data Format as "Treat Text as HTML". It does not work.
    Please advise how I can do that.

    So is there any way to copy the data in Column A into Column B without putting the same formula? something like in Excel where we put "=C1". Its not possible in BI as it comes in excel.....The only way is to create a duplicate column in RPD or Answers screen and incorporate the formula and giving different name to it.
    whats the problem if you duplicate the column with same formula?....Ok still if you dont want to see identical just write some pseudo logic say
    Duplicated column f(x) case when 1=0 then column_name else formula end.....so it appears different to see but it outputs same.
    UPDATED POST
    Dont create in RPD,you can create a dummy column in that report request and change the f(x) to the above case i mentioned by taking the column from columns button in edit formula screen so when ever you edit the actual column formula that would reflect in the dummy column also as it is replicating from original one.Try and see
    hope helps you.
    Cheers,
    KK
    Edited by: Kranthi.K on Jun 2, 2011 1:26 AM

  • After Upgrade into SP 2013 Business data from other SQL DB

    Hi All, We are in process of SP upgrade from 2010 to 2013. We had a basic form in 2010 that was designed using SP Designer 2010. Now after the upgrade, we need to add few new fields (some might be drop-down lists) which will pull business data from SQL Server.
    Could anyone guidelines as how to approach for this?
    My findings & Thoughts: I need to BDC Service Applications (Any specific system requirements to create one in 2013?), then I need to create External Content Types.  I need to add newly created external content types to my existing custom content
    type(?).
    Wondering if there is two way data synchronization available? Meaning say if user has drop-down available which pulls data from SQL Server, If user want to add new items in it. Would it update that field in SQL?
    Any thoughts? Any reference would be appreciated.
    Regards,
    Khushi

    Hi Khushi,
    Hope these links help you-
    http://code.msdn.microsoft.com/SharePoint-2013-Create-ffc9af9f
    http://msdn.microsoft.com/en-us/library/office/jj220063.aspx
    http://technet.microsoft.com/en-us/library/ee661740.aspx
    http://blogs.msdn.com/b/sharepointdev/archive/2011/12/26/understanding-business-connectivity-services.aspx
    Hope this helps!
    Ram - SharePoint Architect
    Blog - SharePointDeveloper.in
    Please vote or mark your question answered, if the reply helps you

  • SCM APO can we copy the data from client 001 to client 002???

    Hi Guru's
    SCM APO can we copy the data from client 001 to client 002???
    If it is possibulity please let me know?
    Regards,
    Sree

    Yes you can do.
    Tcode SCCL.
    Options :
    When copying clients, you can select what you want to transfer from the source client to the target client:
    User masters: You select this option, for example, if you want to give all users of an existing client the same authorizations in the target client.
    Client-specific Customizing: You select this option, for example, if you want to set up a new client in an existing system.
    Client-specific Customizing and master/transaction data:
    You select this option, for example, if you want to set up a test client that is identical to the production client (in the same system).
    Client-specific and cross-client Customizing: You select this option, for example, if you want to set up a quality assurance system based on the production client of another system.
    Client-specific and cross-client Customizing and master/transaction data: You select this option, for example, if you want to set up a test client based on the production client of another system.
    http://help.sap.com/saphelp_46c/helpdata/EN/69/c24c4e4ba111d189750000e8322d00/frameset.htm

  • Is there a simple way to retrieve the data from a resultset using JavaBean?

    I have a result set from a select * from users where userid = xxx statement. However, at the moment I have had to hard code the remainder of the code to get the data from each column as I need the column name as well as its data.
    I had read somewhere using java beans and reflection it is easier. But i do not know know how.
    Is there a simple way to retrieve the data from a result set ?
    thanks in advance-
    kg

    Well, it is not really simple. But there are Open Source components to simplify it for you. See e.g http://www.must.de/Jacompe.htm - de.must.dataobj.DataObject and its subclasses. Feel free to contact me if you have any questions: [email protected]

  • Copy the data from first line while dynamically adding a new line in table

    Hi,
    1. There is a table
    2. An add button adds a new line to the table using 'AddInstance'
    3. A record is entered in the first line
    4. When the add button is clicked it adds a new line and along with it copies the data entered in the first line
    My question is how to copy the data from the first line and show it in the new line added. This is required so that user can use most of the common values in the first line.
    Thanks,
    Nikhil

    You can use the following Java Script in the Click event of the button.
    // Get the number of rows in the table
    var nrows = xfa.resolveNodes("page.table.DATA[*]").length;
    // Add a new instance(row) to the table
    page.table.addInstance.instanceManager(1);
    xfa.form.recalculate(1);
    // Copy the values from the first line to the newly created row
    page.table.DATA\[ nrows \].field1.rawValue = page.table.DATA\[ 0 \].field1.rawValue;
    ..........field2
    ..........field3
    Thanks,
    Chandra Indukuri

  • If meta data LUN is totaly destroied , is there any way to rebuild the data from the video LUN

    If meta data LUN is totaly destroied , is there any way to rebuild the data from the video LUN ????

    What happened to your metadata? Are you sure the metadata is gone?
    In theory, file carving could be attempted on the data LUNs, but you would need a tool that understands how Xsan lays out data across LUNs in a stripe group and hope your fragmentation isn't too bad. I doubt such a tool exists, but if one does it almost certainly is not publicly available. You should probably contact a data recovery service with experience recovering data from Xsan. Do that before you do anything else if this data is really important.

  • User exit to copy the data from sales order to billing document

    hi everyone,
    Is there an user exit to copy the data from sales order to billing document?
    Regards
    Prabudh

    hi
    copy control would be the better option to choose.. but still u can a give a search in list below and opt for the right one..Refer to the link below..
    http://www.planetsap.com/Userexit_List.htm
    User exits for Sales order
    1•USEREXIT_DELETE_DOCUMENT
    2•USEREXIT_FIELD_MODIFICATION
    3.•USEREXIT_MOVE_FIELD_TO_VBAK
    4.•USEREXIT_NUMBER_RANGE
    5.•USEREXIT_SAVE_DOCUMENT
    User exits for billing
    1.•USEREXIT_ACCOUNT_PREP_KOMKCV (Module pool SAPLV60A, program RV60AFZZ)
    2.•USEREXIT_ACCOUNT_PREP_KOMPCV
    3•USEREXIT_NUMBER_RANGE_INV_DATE (Module pool SAPLV60A, program RV60AFZC)
    4•USEREXIT_PRINT_ITEM (Module pool SAPLV61A, program RV61AFZB
    5.USEREXIT_PRINT_HEAD (Modulpool SAPLV61A, Programm RV61AFZB)
    Reward if Useful
    Thanx & Regards..
    Naren..

Maybe you are looking for

  • How do i set up multiple apple iPhones with one account?

    Iphones are merging contact info and text messages.  sharing icloud.

  • 8800 headphone issues

    Once I surrendered to the fact that my Blackberry 8800 ( tmobile ) would not allow me to use my s9 stereo bluetooth headphones >sigh<  I purchased a pair of "Body Glove" wired stereo headphones that had the correct size adapter. I listen to my music

  • How do i get someone else out of my apple id?

    Hi guys, im using an iphone 4 to play this game Clash of Clans and recently, when i'm playing the game, i get the notification that someone else is playing which means that he has access to my apple id. Due to that im very frustrated and helpless...

  • Create dblink in Oracle/Linux (RHEL4) to MS SQL Server/Windows?

    Hi, Can anyone share me the procedure to Create dblink in Oracle/Linux (RHEL4) to MS SQL Server/Windows? Thanks

  • Trouble Pre-ording

    Hi, I'm currently trying to pre-order the album EndGame by Rise Against, but every time I try to it pops up with three different messages. Note I have already purchased their single "Architects". The three messages are as follows: 1) *Are you sure yo