How to import a text file into oracle
DBAsupport.com Forums - Powered by vBulletin
Results 1 to 4 of 4

Thread: How to import a text file into oracle

Hybrid View

  1. #1
    Join Date
    Oct 2001
    Posts
    16
    Hi friends,

    is there anyway to store text files like
    .txt, .sql as a part of oracle.
    i want to put all my oracle sql code there.


    thanx a lot.
    gautam
    Gautam Bhagwandas

    Web Site : www.geocites.com/gautamzone

  2. #2
    Join Date
    Jan 2001
    Location
    Vancouver, Canada
    Posts
    87
    Yes, you can by using LOB data types in table and then using sqlloader to import data in table.
    Download Oracle application developer's guide from http://otn.oracle.com.

    Cheers!

    Mohammad Zahid
    Software Developer
    Database Management Applications.
    Vancouver, Canada
    E-mail: mzahid@shaw.ca

  3. #3
    Join Date
    May 2001
    Posts
    25
    You can upload the data from the text file into the Oracle Table through SQL Loader Utilityof the Oracle. In the text file you have to define the each column with some delimiter like space or comma etc..

    You have to use two more file, One is as Control and Another is as Log file.

    You have to define column name of the table in the control file. And log file shows the status of the loading of the data. How much data loaded and how much data not loaded due to some error.


    Only through SQL Loader you can migrate the data from one application to oracle.


    Naresh Kakrani
    DBA - Reliance
    nkakrani@yahoo.com

  4. #4
    Join Date
    Dec 2001
    Location
    Brazil
    Posts
    282

    Excuse me, I might have understood wrong, but you want to export or import a script?

    " i want to put all my oracle sql code there. "


    if you want to put all your sql code into a .txt or .sql file use SQL*Plus spool command.

    -----------
    spool c:\expcode.txt

    // script code

    spool off
    -----------


    F.



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