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

Thread: exporting certain columns of a table

  1. #1
    Join Date
    Oct 2009
    Posts
    30

    exporting certain columns of a table

    Hi,

    I want to export only few columns of a table and import the same in another database.

    Please guide me.

    Thanks in advance.
    Regards,
    Aakriti

  2. #2
    Join Date
    Mar 2006
    Location
    Charlotte, NC
    Posts
    865
    as far as i know we have no option to do that. Instead, you can create another table with CTAS with the required columns, export that table and import in the another database.

    Thanks,
    Vijay Tummala

    Try hard to get what you like OR you will be forced to like what you get.

  3. #3
    Join Date
    Oct 2008
    Location
    Chandigarh, India
    Posts
    322
    won't the QUERY parameter in expdp help?
    I haven't tried it though.
    lucky

  4. #4
    Join Date
    Mar 2007
    Location
    Ft. Lauderdale, FL
    Posts
    3,555
    Quote Originally Posted by mahajanakhil198 View Post
    won't the QUERY parameter in expdp help?
    As far as I remember query parameter defines a predicate a.k.a. "where clause" so, if I'm correct this is not directly doable.

    What I would do is create an intermediate table then export that table like...

    create table MyIntTable
    as
    select list-of-desired-columns
    from MySourceTable;
    commit;

    Then export MyIntTable.
    Last edited by PAVB; 04-05-2010 at 04:08 PM. Reason: typo
    Pablo (Paul) Berzukov

    Author of Understanding Database Administration available at amazon and other bookstores.

    Disclaimer: Advice is provided to the best of my knowledge but no implicit or explicit warranties are provided. Since the advisor explicitly encourages testing any and all suggestions on a test non-production environment advisor should not held liable or responsible for any actions taken based on the given advice.

  5. #5
    Join Date
    Sep 2002
    Location
    England
    Posts
    7,334
    Quote Originally Posted by mahajanakhil198 View Post
    won't the QUERY parameter in expdp help?
    I haven't tried it though.

    how about trying it first then

  6. #6
    Join Date
    Apr 2007
    Location
    USA
    Posts
    110
    Quote Originally Posted by vnktummala View Post
    as far as i know we have no option to do that. Instead, you can create another table with CTAS with the required columns, export that table and import in the another database.

    Thanks,
    you are right....
    Looking for the greatest evil in the world? Look in the mirror.

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