how can i read files from a pl/sq l program
Answers were Sorted based on User's Feedback
Answer / guru
__________________________________________________________
DECLARE
fileHandler UTL_FILE.FILE_TYPE;
BEGIN
fileHandler := UTL_FILE.FOPEN('/tmp', 'myfile', 'R');
UTL_FILE.PUTF(fileHandler, 'Look ma, I''m writing to a
file!!!\n');
UTL_FILE.FCLOSE(fileHandler);
EXCEPTION
WHEN utl_file.invalid_path THEN
raise_application_error(-20000, 'ERROR: Invalid path
for file or path not in INIT.ORA.');
END;
/
________________________________________________________
Thanks
| Is This Answer Correct ? | 3 Yes | 0 No |
Answer / swayamji
SELECT TEXT FROM USER_SOURCE WHERE NAME LIKE '<SUB PROGRAM
NAME>'
| Is This Answer Correct ? | 0 Yes | 3 No |
What is sql constant?
What are tables in sql?
Why do we use subquery?
cursor types? explain with example programs?
What are the difference between Functions/Stored Procs and Triggers and where are they used.
Explain how procedures and functions are called in a PL/SQL block ?
What is self-join and what is the requirement of self-join?
What is data profiling in sql?
How do I find duplicates in sql?
which tcp/ip port does sql server run on? : Sql dba
In table three columns with 1 milion records(here there is no sequence values) i want add one more column with sequence values from the first how it is posible?
What are the different tcl commands in sql?
Oracle (3259)
SQL Server (4518)
MS Access (429)
MySQL (1402)
Postgre (483)
Sybase (267)
DB Architecture (141)
DB Administration (291)
DB Development (113)
SQL PLSQL (3330)
MongoDB (502)
IBM Informix (50)
Neo4j (82)
InfluxDB (0)
Apache CouchDB (44)
Firebird (5)
Database Management (1411)
Databases AllOther (288)