Answer Posted / avi007
DECLARE
fileHandler UTL_FILE.FILE_TYPE;
BEGIN
fileHandler := UTL_FILE.FOPEN('/tmp', 'myfile', 'W');
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;
/
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
What is meant by truncate in sql?
How to start oracle sql developer?
Explain what is a database?
How can I see all tables in sql?
What is the difference between a primary key and a clustered index?
What are inner and outer joins examples of both?
What are the methods of filing?
Can cursors be part of a trigger body?
List the ways to get the count of records in a table?
Show code of a cursor for loop.
Do triggers have restrictions on the usage of large datatypes, such as long and long raw?
How many times can we commit in a loop?
give the syntax of grant and revoke commands? : Sql dba
what is online transaction processing (oltp)? : Sql dba
What is the max nvarchar size?