忙裏偷閑

很多事情很多心情寫了也就記下了; 不寫,以後可能就忘了.
個人資料
正文

Oracle Directories

(2009-03-31 15:25:20) 下一個

In oracle, we can define object 'Directory', so in PL/SQL, we can refer the directory object.

For example, directory object 'XX_EXPORT_TO_BAAN' is defined.

Then in PL/SQL block, we can refer it like below.

l_out_dir varchar2(50) := 'XX_EXPORT_TO_BAAN';
l_out_file varchar2(50) := 'o'||fnd_profile.value('CONC_REQUEST_ID')||'.out';
l_out_file varchar2(50) := 'ACT_LINE_TO_BAAN.txt';
l_conn UTL_TCP.connection;
v_file UTL_FILE.FILE_TYPE;

v_file := UTL_FILE.FOPEN(location => l_out_dir,
                                             filename => l_out_file,
                                             open_mode => 'w',
                                             max_linesize => 32767);

[ 打印 ]
閱讀 ()評論 (1)
評論
目前還沒有任何評論
登錄後才可評論.