I have problem using the UTL_FILE package. I just want to store text information in an external file.
It works properly with UTL_FILE.PUT_LINE.
but not with UTL_FILE.PUT() and UTL_FILE.PUTF().
code doesn't give any error, it creates my file but it doesn't write anything in the file.
please help me!
here is my code :
_____________________________________________
BEGIN
str_ImageFile := 'temp.jpg';
outfile := utl_file.fopen('D:\TEMP\',str_ImageFile ,'w');
tempstring := 'THIS IS A TEST';
--UTL_FILE.PUT(outfile, tempstring);
--UTL_FILE.PUTF(outfile, '%s', tempstring);
UTL_FILE.PUT_LINE(outfile, tempstring);
UTL_FILE.FCLOSE_ALL();
END;
______________________________________________
It works properly with UTL_FILE.PUT_LINE.
but not with UTL_FILE.PUT() and UTL_FILE.PUTF().
code doesn't give any error, it creates my file but it doesn't write anything in the file.
please help me!
here is my code :
_____________________________________________
BEGIN
str_ImageFile := 'temp.jpg';
outfile := utl_file.fopen('D:\TEMP\',str_ImageFile ,'w');
tempstring := 'THIS IS A TEST';
--UTL_FILE.PUT(outfile, tempstring);
--UTL_FILE.PUTF(outfile, '%s', tempstring);
UTL_FILE.PUT_LINE(outfile, tempstring);
UTL_FILE.FCLOSE_ALL();
END;
______________________________________________