PLSQL的UTL_FILE使用例子
生活随笔
收集整理的這篇文章主要介紹了
PLSQL的UTL_FILE使用例子
小編覺(jué)得挺不錯(cuò)的,現(xiàn)在分享給大家,幫大家做個(gè)參考.
開(kāi)始
前期準(zhǔn)備:
SQL> create directory utl as '/home/oracle/test'; Directory created.SQL> grant execute on utl_file to scott; Grant succeeded.SQL>文件操作:
declarefn utl_file.file_type;OutputRecord VARCHAR2(255); beginOutputRecord :='abcdefg';fn:=utl_file.fopen('UTL','test.txt','W');utl_file.put (fn, OutputRecord);utl_file.new_line (OutputFile);utl_file.fclose(fn); end;結(jié)束
轉(zhuǎn)載于:https://www.cnblogs.com/gaojian/archive/2012/12/06/2805226.html
總結(jié)
以上是生活随笔為你收集整理的PLSQL的UTL_FILE使用例子的全部?jī)?nèi)容,希望文章能夠幫你解決所遇到的問(wèn)題。
- 上一篇: sql语句总结一
- 下一篇: linux cmake编译源码,linu