• 222

    The example given below for writing text file or CSV using Text_IO package from a tabular block in Oracle Forms.  Suppose there is a tabular grid data block “Job_History” in your forms and you want to write a CSV on click of a button by reading whole block from top to bottom. The following is ...
  • 214

    Below is the example to write file on client in Oracle Forms 10g with webutil library package. Note:  Webutil library must be attached to the form. DECLAREv_dir VARCHAR2(250) := ‘c:temp’;ft_tempfile CLIENT_TEXT_IO.FILE_TYPE;beginft_tempfile := CLIENT_TEXT_IO.FOPEN(v_dir ||’tempfile.txt’,’w’);CLIENT_TEXT_IO.PUT_LINE(ft_tempfile,’First line….’);CLIENT_TEXT_IO.PUT_LINE(ft_tempfile,’Second line….’);CLIENT_TEXT_IO.PUT_LINE(ft_tempfile,’Third line….’);CLIENT_TEXT_IO.FCLOSE(ft_tempfile);END; Writing Text Files in Oracle Forms 10gReviewed by Nisha Vats onMar 01Rating: 4.5
  • 208

    Below is the example to read and import comma delimited csv file in oracle forms with D2k_Delimited_String package. This package is available in D2kdlstr.pll library. To download D2kdlstr.Pll Click Here Create the following procedure in program unit of Oracle forms. Procedure Import_csv_file (I_FILENAME IN VARCHAR2) Is   — Text File Type   Infile        Text_Io.File_Type;   Linebuf       Varchar2 (4000);   ...
  • 181

    Upload Files To FTP in Oracle Forms D2k Use following procedure to upload files to Ftp.  PROCEDURE Ftp_Upload IS    outfile text_io.file_type;BEGIN    — write a ftp script    outfile := text_io.fopen(‘D:ftpsendsource.ftp’, ‘w’);    text_io.put_line(outfile, ‘open yourftpurl’);    text_io.put_line(outfile, ‘youruser’);    text_io.put_line(outfile, ‘yourpassword’);    text_io.put_line(outfile,’binary’);    text_io.put_line(outfile,’send D:TempTest1.txt’);    text_io.put_line(outfile,’send D:TempTest2.abc’);    text_io.put_line(outfile,’disconnect’);    text_io.put_line(outfile,’bye’);    text_io.fclose(outfile);    host(‘cmd /c ftp -s:d:ftpsendsource.ftp’);    exception         when others then        ...
  • 182

    Suppose you want to read a file from D2k client and want to store its content in Oracle database. But if you will insert row by row from client to server it will take more time and increase lot of network traffic / round trips. The solution of this problem is to store the content ...