file input and output [message #598451] |
Tue, 15 October 2013 01:56 |
|
saurau
Messages: 3 Registered: October 2013 Location: Bangalore
|
Junior Member |
|
|
Hello Everybody,
I am very new to oracle and having a query, i need a script which can take input from a file and give output to other txt file, something like below :
input.txt
001
002
003
004
Query:
select name from employee where employeecode=<ENTRY FROM INPUT.TXT FILE>
Result should go to OUTPUT.TXT File.
Your help is highly appreciated.
Regards,
saurau.
|
|
|
|
|
|
|
|
|
Re: file input and output [message #598460 is a reply to message #598458] |
Tue, 15 October 2013 02:47 |
Lalit Kumar B
Messages: 3174 Registered: May 2013 Location: World Wide on the Web
|
Senior Member |
|
|
Why UTL_FILE? No need in your case.
If it is in the client side, then simply use sqlldr to load into the existing table and then use SPOOL to create an output file based on your select query. You could write a script to automate all these steps into one.
[Updated on: Tue, 15 October 2013 02:48] Report message to a moderator
|
|
|