aspose file tools*
The moose likes Oracle/OAS and the fly likes How to unload the table data to a txt file. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » Oracle/OAS
Bookmark "How to unload the table data to a txt file." Watch "How to unload the table data to a txt file." New topic
Author

How to unload the table data to a txt file.

aresh babu
Ranch Hand

Joined: Aug 31, 2008
Posts: 65
Hi All,

Please let us know how to unload oracle table data to a normal file..
Jeanne Boyarsky
internet detective
Marshal

Joined: May 26, 2003
Posts: 30512
    
150

Not sure what you mean by a normal file. Maybe export the table to csv (comma separated value) ?


[Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Blogging on Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, OCAJP, OCPJP beta, TOGAF part 1 and part 2
Badal Chowdhary
Ranch Hand

Joined: Apr 26, 2011
Posts: 34

If it is a one time process, then you could export the file as Jeanne suggested.

If this would be called frequently, then following are some options:
1) Write a procedure that writes data to a file using utl_file package
2) Write a program (eg using JDBC) that iterates through the resultset and writes data to a file using BufferedWriter.

Thanks,
Badal


Blog: http://badalchowdhary.wordpress.com/
Twitter: http://twitter.com/badalrocks
aresh babu
Ranch Hand

Joined: Aug 31, 2008
Posts: 65
Hi Jeanne ,

i want to load into in a CSV or .txt file.

Please let me know how can i load the data from a table to CSV file without using java(jdbc,hibernate)..

Thanks & Regards
Aresh babu
 
jQuery in Action, 2nd edition
 
subject: How to unload the table data to a txt file.