Uploading csv file into database using apex

Dear all
I am using apex 4 and oracle express 10g, i need to upload .csv file into the database for one of my appls, i have referred discussion forum for solutions, i found also, but some how its not working for me.
below mentioned is error and the code
ERROR:
ORA-06550: line 38, column 8: PLS-00221: 'V_DATA_ARRAY' is not a procedure or is undefined ORA-06550: line 38, column 8: PL/SQL: Statement ignored ORA-06550: line 39, column 8: PLS-00221: 'V_DATA_ARRAY' is not a procedure or is undefined ORA-06550: line 39, column 8: PL/SQL: Statement ignored ORA-06550: line 40, column 8: PLS-00221: 'V_DATA_ARRAY' is not a procedure or is undefined ORA-06550: line 40, column 8: PL/SQL: Statement ignored ORA-06550: line 41, column 8: PLS-00221: 'V_DATA_ARRAY' is not a proc
Error
OK
CODE:
DECLARE
v_blob_data BLOB;
v_blob_len NUMBER;
v_position NUMBER;
v_raw_chunk RAW(10000);
v_char CHAR(1);
c_chunk_len number := 1;
v_line VARCHAR2 (32767) := NULL;
v_data_array wwv_flow_global.vc_arr2;
BEGIN
-- Read data from wwv_flow_files
select blob_content into v_blob_data
from wwv_flow_files where filename = 'DDNEW.csv';
v_blob_len := dbms_lob.getlength(v_blob_data);
v_position := 1;
-- Read and convert binary to char
WHILE ( v_position <= v_blob_len ) LOOP
v_raw_chunk := dbms_lob.substr(v_blob_data,c_chunk_len,v_position);
v_char := chr(hex_to_decimal(rawtohex(v_raw_chunk)));
v_line := v_line || v_char;
v_position := v_position + c_chunk_len;
-- When a whole line is retrieved
IF v_char = CHR(10) THEN
-- Convert comma to : to use wwv_flow_utilities
v_line := REPLACE (v_line, ',', ':');
-- Convert each column separated by : into array of data
v_data_array := wwv_flow_utilities.string_to_table (v_line);
-- Insert data into target table
EXECUTE IMMEDIATE 'insert into TABLE_X (v1, v2, v3, v4 ,v5, v6, v7,v8 ,v9, v10, v11)
values (:1,:2,:3,:4,:5,:6,:7,:8,:9,:10,:11)'
USING
v_data_array(1),
v_data_array(2),
v_data_array(3),
v_data_array(4);
v_data_array(5);
v_data_array(6);
v_data_array(7);
v_data_array(8);
v_data_array(9);
v_data_array(10);
v_data_array(11);
-- Clear out
v_line := NULL;
END IF;
END LOOP;
END;
what i understand from this is system does not identify v_data_array as array for some reasons, please help me.
initially system was giving error for hex_to_decimal, but i managed to get this function on discussion forum and now it seems to be ok. but v_data_array problem is still there.
thanks in advance
regards
Uday

Hi,
Mistakes in your sample I did correct
Problem 1
select blob_content into v_blob_data
from wwv_flow_files where filename = 'DDNEW.csv'; to
select blob_content into v_blob_data
from wwv_flow_files where name = :P1_FILE;Problem 2
EXECUTE IMMEDIATE 'insert into TABLE_X (v1, v2, v3, v4 ,v5, v6, v7,v8 ,v9, v10, v11)
values (:1,:2,:3,:4,:5,:6,:7,:8,:9,:10,:11)'
USING
v_data_array(1),
v_data_array(2),
v_data_array(3),
v_data_array(4);
v_data_array(5);
v_data_array(6);
v_data_array(7);
v_data_array(8);
v_data_array(9);
v_data_array(10);
v_data_array(11);  to
EXECUTE IMMEDIATE 'insert into TABLE_X (v1, v2, v3, v4 ,v5, v6, v7,v8 ,v9, v10, v11)
values (:1,:2,:3,:4,:5,:6,:7,:8,:9,:10,:11)'
USING
v_data_array(1),
v_data_array(2),
v_data_array(3),
v_data_array(4),
v_data_array(5),
v_data_array(6),
v_data_array(7),
v_data_array(8),
v_data_array(9),
v_data_array(10),
v_data_array(11);  And I did create missing table
CREATE TABLE TABLE_X
    v1  VARCHAR2(255),
    v2  VARCHAR2(255),
    v3  VARCHAR2(255),
    v4  VARCHAR2(255),
    v5  VARCHAR2(255),
    v6  VARCHAR2(255),
    v7  VARCHAR2(255),
    v8  VARCHAR2(255),
    v9  VARCHAR2(255),
    v10 VARCHAR2(255),
    v11 VARCHAR2(255)
  );Regards,
Jari
Edited by: jarola on Nov 19, 2010 3:03 PM

Similar Messages

  • How to regularly load data from .csv file to database (using apex)

    Hi,
    i am using apex3 , I need to load data from a csv file to apex . I need to perform this automatically through code at regular time interval of 5-10 seconds.
    Is it possible .If yes how ?. Please reply as early as possible. This will decide whether to use apex or not for this application.
    this is question for Application Express. Dont know why in forum for BPEL
    Edited by: TEJU on Oct 24, 2008 2:57 PM

    Hello,
    You really need to load the data every 5-10 seconds? Presumably it's read only?
    I would look at using an Oracle external table instead, that way you just drop your CSV in a location the DB can read it and then you build a table that essentially references the underlying CSV (that way when you query the table you view the data in the CSV file).
    Take a look at this link for a quick example on usage -
    http://www.oracle-base.com/articles/9i/SQLNewFeatures9i.php#ExternalTables
    Hope this helps,
    John.
    Blog: http://jes.blogs.shellprompt.net
    Work: http://www.apex-evangelists.com
    Author of Pro Application Express: http://tinyurl.com/3gu7cd
    REWARDS: Please remember to mark helpful or correct posts on the forum, not just for my answers but for everyone!

  • How to upload a file to database in Apex 4.2.2?

    How to upload a file to database in Apex 4.2.2 in Existing Application? Also How to view the uploaded file within this application?
    Any help to his question is very appreciated?
    Thanks,
    Prak.

    980835 wrote:
    Please update your forum profile with a real handle instead of "980835".
    Actually we want to upload the file to our own table and retrive from it as well. Is it possible to see the file of person whom we are pulling?
    This is covered in the documentation: About BLOB Support in Forms and Reports. There's also a tutorial in the Oracle Learning Library.

  • How to upload a file into server using j2ee jsp and servlet with bean?

    How to upload a file into server using j2ee jsp and servlet with bean? Please give me the reference or url about how to do that. If related to struts is more suitable.
    Anyone help me please!

    u don't need j2ee and struts to do file uploading. An example is as such
    in JSP. u use the <input> file tag like
    <input type="file"....>You need a bean to capture the file contents like
    class FileUploadObj {
        private FormFile srcFile;
        private byte[] fileContent;
        // all the getter and setter methods
    }Then in the servlet, you process the file for uploading
        * The following loads the uploaded binary data into a byte Array.
        FileUploadObj form = new FileUploadObj();
        byte[] byteArr = null;
        if (form.signFile != null) {
            int filesize = form.srcFile.getFileSize();
            byteArr = new byte[filesize];
            ByteArrayInputStream bytein = new ByteArrayInputStream (form.srcFile.getFileData());
            bytein.read(byteArr);
            bytein.close();
            form.setFileContent(byteArr);
        // Write file content using Writer class into the destination file in the server.
        ...

  • Upload multiple excel files into tables using APEX

    Hi folks,
    I'm wondering if anyone has ever uploaded multiple .csv files simultaniously and store the data into the database using APEX XE before.
    I can browse for a single file, and execute that okay and a good example of doing that can be found at http://advait.wordpress.com/2008/05/21/uploading-excel-sheet-using-oracle-application-express-apex/
    This works fine when the user browses to a specific file on their network and then uploads the data from that one file.
    However I need the ability to 'grab' every file in a specific directory one after the other to process rather than having to specify which one to load everytime, and wondered if anyone has come across this before.
    Many thanks
    Graham.

    Just for completeness ...
    Got this to work, but it's a pl/sql issue as opposed to an APEX issue.
    Anyway, if anyone needs to have the ability to read multiple files then a quick easy way to do it (as lomg as they know the file names that will be read), is to create a directory on the database which points to the actual harddrive on your PC, then create a table (called an external table) and read from that external table as if it was an actual database table ...
    1 - Log on as sys and grant CREATE ANY DIRECTORY to whatever user you are logging in as (assuming you are not using sys to create apps)
    2 - Create a directory e.g....CREATE OR REPLACE DIRECTORY GB_TEST AS 'c:\gbtest';
    3 - Create an external table as ...
    CREATE TABLE gb_test
    (file_name varchar2(10),
    rec_date date
    rec_name VARCHAR2(20),
    rec_age number,
    ORGANIZATION EXTERNAL
    TYPE ORACLE_LOADER
    DEFAULT DIRECTORY GB_TEST
    ACCESS PARAMETERS
    RECORDS DELIMITED BY NEWLINE
    FIELDS TERMINATED BY ','
    LOCATION ('data1.csv','data2.csv','data3.csv','data4.csv')
    PARALLEL 5
    REJECT LIMIT 20000;
    That's it then ...
    select * from gb_test
    where file_name = 'xxx'
    will return all the data where the file_name = 'xxx'
    very easy to use.

  • Error for the uploading csv file to database

    Hi i tried to upload the csv file to database and i am getting error as
    <cffile action="read" file="#data_dir_upload#/di_audit_corp_upc_ldr_tbl.csv" variable="di_audit_corp_upc_ldr_tbl">
    <!--- loop through the CSV-TXT file on line breaks and insert into database --->
    <cfloop index="index" list="#di_audit_corp_upc_ldr_tbl#" delimiters="#chr(10)##chr(13)#">
        <cfquery  datasource="#request.dsnCAO#">   
                <!--- SET ANSI_WARNINGS OFF      --->
             INSERT INTO [dbo].[di_audit_corp_upc_ldr_tbl]
                                ( cpt_dpt_cd,cpt_com_cd,sub_com_cd,con_upc_no,pid_lng_dsc_tx,pid_sht_dsc_tx)
             VALUES
                      (<cfqueryparam value='#left(trim(listgetAt('#index#',2,',')),2)#' cfsqltype="cf_sql_char">,
                       <cfqueryparam value='#left(trim(listgetAt('#index#',3,',')),3)#' cfsqltype="cf_sql_char">,
                       <cfqueryparam value='#left(trim(listgetAt('#index#',4,',')),5)#' cfsqltype="cf_sql_char">,
                       <cfqueryparam value='#left(trim(listgetAt('#index#',1,',')),13)#' cfsqltype="cf_sql_varchar">,                  
                       <cfqueryparam value='#left(trim(listgetAt('#index#',5,',')),25)#' cfsqltype="cf_sql_varchar">,
                       <cfqueryparam value='#left(trim(listgetAt('#index#',6,',')),12)#' cfsqltype="cf_sql_varchar">)    
       </cfquery>
    </cfloop>
    Error:
    An error occurred while executing DTS package to import data.
    Invalid list index 6.
    In function ListGetAt(list, index [, delimiters]), the value of index, 6, is not a valid as the first argument (this list has 5 elements). Valid indexes are in the range 1 through the number of elements in the list.
    i am unable to solve this issue can any one will help me to solve this issue
    Thanks,
    Kiran

    I take it your are trying to use a csv file to insert new data into a database, using flex and coldfusion?
    if so, then I would load the file in flex using cffile in ColdFusion and then use Load Data if you are using MySQL
    This can show you more about it.
    http://blog.tygate.com/?p=75
    We get very large csv files ftp'd to us every week, and we have to load them in to the db. this works for us.

  • Upload .txt file into Database Table

    Hi,
    I was wondering if someone could please point me in the right direction. I've been looking around the forum but can't find anything to help me achieve the following.
    I would like to be able to upload a .txt file using a webpage. Then store the information inside this file into database tables.
    eg. contents of mytextfile.txt:
    richard
    10 anywhere street, anytown, somewhere
    111 222 333 444
    joe
    9 somestreet, elsewhere
    999 888 777 666
    peter
    214 nearby lane, overhere
    555 555 555 555
    I would like to insert this data into a table.
    eg. table name = CONTACTS
    userid = primary key (using sequence)
    username = (line 1 - richard, joe, peter)
    address = (line 2)
    phone_no = (line 3)
    As you can see the records will appear 1 at a time and will have a blank line between records. Is there anyway for me to upload a file like this and have it placed into tables?
    I have seen http://otn.oracle.com/products/database/htmldb/howtos/howto_file_upload.html but this seems to be for uploading a whole file and downloading the same file, rather than extracting data from the file.
    I hope I have managed to explain my problem.
    Many thanks,
    Richard.

    Richard,
    HTML DB allows you to upload CSV files via the Data Workshop. That data would then be parsed and inserted into a specific table. Alternatively, if you have your data in an Excel spreadsheet, and it is less than 32k, you can copy & paste the data directly into HTML DB's Data Workshop, which will then parse and import it into the Oracle database.
    The one obstacle you may have to overcome is converting your data from the format you outlined to CSV format. Specifically, you would have to make this:
    richard
    10 anywhere street, anytown, somewhere
    111 222 333 444
    Look something like this:
    "richard","10 anywhere street, anytown, somewhere","111 222 333 444"
    Hope this helps,
    - Scott -

  • Getting Issue while uploading CSV file into internal table

    Hi,
    CSV file Data format as below
         a             b               c              d           e               f
    2.01E14     29-Sep-08     13:44:19     2.01E14     SELL     T+1
    actual values of column   A is 201000000000000
                     and  columen D is 201000000035690
    I am uploading above said CSV file into internal table using
    the below coding:
    TYPES: BEGIN OF TY_INTERN.
            INCLUDE STRUCTURE  KCDE_CELLS.
    TYPES: END OF TY_INTERN.
    CALL FUNCTION 'KCD_CSV_FILE_TO_INTERN_CONVERT'
        EXPORTING
          I_FILENAME      = P_FILE
          I_SEPARATOR     = ','
        TABLES
          E_INTERN        = T_INTERN
        EXCEPTIONS
          UPLOAD_CSV      = 1
          UPLOAD_FILETYPE = 2
          OTHERS          = 3.
      IF SY-SUBRC <> 0.
        MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
                WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    am getting all columns data into internal table,
    getting problem is columan A & D. am getting values into internal table for both; 2.01E+14. How to get actual values without modifying the csv file format.
    waiting for your reply...
    thanks & regards,
    abhi

    Hi Saurabh,
    Thanks for your reply.
    even i can't double click on those columns.
    b'se the program needs be executed in background there can lot of csv file in one folder. No manual interaction on those csv files.
    regards,
    abhi

  • How can I import data from a csv file into databse using utl_file?

    Hi,
    I have two machines (os is windows and database is oracle 10g) that are not connected to each other and both are having the same database schema but data is all different.
    Now on one machine, I want to take dump of all the tables into csv files. e.g. if my table name is test then the exported file is test.csv and if the table name is sample then csv file name is sample.csv and so on.
    Now I want to import the data from these csv files into the tables on second machine. if I've 50 such csv files, then data should be written to 50 tables.
    I am new to this. Could anyone please let me know how can I import data back into tables. i can't use sqlloader as I've to satisfy a few conditions while loading the data into tables. I am stuck and not able to proceed.
    Please let me know how can I do this.
    Thanks,
    Shilpi

    Why you want to export into .csv file.Why not export/import? What is your oracle version?
    Read http://www.oracle-base.com/articles/10g/oracle-data-pump-10g.php
    Regards
    Biju

  • How to batch upload PDF files into database BLOB

    Hello.
    I have a requirement to batch upload PDF files into BLOB column of an Oracle 8.1.7 table from Forms 6i Web. The content of the blob column (ie. the PDF content) MUST be displayable from all client software (eg. Oracle Web forms, HTML forms, etc.)
    Our environment is
    Middle-tier is 9iAS on Windows/2000
    Database is Oracle 8.1.7.0.0 on VMS
    Oracle Web Forms 6i Patch 10
    Basically my Oracle web form program will display a list of PDF files to upload and then the user can click on the &lt;Upload&gt; button to do the batch upload. I have experimented the following approaches but with no luck.
    1. READ_IMAGE_FILE forms built-in = does NOT work because it cannot read PDF file. I got error FRM-47100: Cannot read image file
    2. OCX and OLE form item = cannot use this because it does NOT work on the Web. I got error FRM-41344 OLE object not defined
    3. I cannot use DBMS_LOB to do the load because the PDF files are not in the database machine.
    4. Metalink Note 1682771.1 (How to upload binary documents back to database blob column from forms). When I used this, I got ORA-6502 during the hextoraw conversion. In using this solution, I have downloaded a bin2hex.exe from the Google site. I've noticed that when I looked at the converted HEX file, each line has the character : (colon) at the beginning of each line. I know the PDF file has been converted correctly to HEX format because when I convert the HEX file back to BIN format using hex2bin.exe, I'm able to display the converted bin file in Acrobat Reader. When I removed the : (colon) in the HEX file, I did NOT get the ORA-6502 error but I CANNOT display the file in Acrobat Reader. It gives an error "corrupted file".
    5. upload facility in PL/SQL Web toolkit - I tried to automatically submit the html form (with htp.p) but it does NOT load the contents of the file. I called the URL from Oracle forms using web.show_document. There seems to be issues with Oracle Web forms (JInitiator) and HTML (+ htp.p).
    The other options I can think of at this point are:
    1. Use SQL*Loader to do the batch upload via SQL*Net connection and use HOST() built-in from Oracle Webforms to execute SQL*Loader from the 9iAS.
    2. Write a Visual Basic program that reads a binary file and output the contents of the file into a byte array. Then build a DLL that can be called from Oracle webforms 6i via ORA_FFI. I don't prefer this because it means the solution will only work for Windows.
    3. Write a JSP program that streams the PDF file and insert the contents of the PDF file into blob column via JDBC. Call JSP from forms using web.show_document. With this I have to do another connection to the database when I load the file.
    4. Maybe I can use dbms_lob by using network file system (NFS) between the application server and VMS. But this will be network resource hungry as far as I know because the network connection has to be kept open.
    Please advise. Thank you.
    Regards,
    Armando

    I have downloaded a bin2hex.exe from the Google site.
    ... each line has the character : (colon) at the
    beginning of each line. I'm afraid it isn't a correct utility. I hope you'll find the source code of a correct one at metalink forum:
    Doc ID: 368771.996
    Type: Forum
    Subject: Uploading Binary Files: bin2hex and hex2bin do not reproduce the same file
    There is some links to metalink notes and some example about working with BLOB at http://www.tigralen.spb.ru/oracle/blob/index.htm. Maybe it helps. Sorry for my English. If there is any problem with code provided there, let me know by e-mail.

  • Uploading CSV file into Webdynpro abap application

    Hi all,
    Please let me know the process of uploading .csv file in Webdynpro(ABAP) using FILE_UPLOAD UI element.
    Thanks
    Subathra

    Hi,
    you can use the following code ..........
    assumiing the file cointain tow colums name and age
    TYPES :
           BEGIN OF str_itab,
           name(10) TYPE c,
           age(10) TYPE c,
           END OF str_itab.  DATA : t_table1 TYPE STANDARD TABLE OF str_itab,
             i_data TYPE STANDARD TABLE OF string,
             lo_nd_sflight TYPE REF TO if_wd_context_node,
             lo_el_sflight TYPE REF TO if_wd_context_element,
             l_string TYPE string,
             fs_table TYPE str_itab,
             l_xstring TYPE xstring,
             fields TYPE string_table,
             lv_field TYPE string.  DATA : t_table TYPE if_main=>elements_data_tab,
             data_table TYPE if_main=>elements_data_tab.
    get single attribute 
    wd_context->get_attribute(    EXPORTING      name =  `DATASOURCE`    IMPORTING      value = l_xstring ).
      CALL FUNCTION 'HR_KR_XSTRING_TO_STRING'
        EXPORTING
          in_xstring = l_xstring
        IMPORTING
          out_string = l_string.
    SPLIT l_string  AT cl_abap_char_utilities=>newline INTO TABLE i_data.
    Bind With table Element.  LOOP AT i_data INTO l_string.
        SPLIT l_string AT cl_abap_char_utilities=>horizontal_tab INTO TABLE fields.   
        READ TABLE fields INTO lv_field INDEX 1.
        fs_table-name = lv_field.   
        READ TABLE fields INTO lv_field INDEX 2.
        fs_table-age = lv_field.    APPEND fs_table TO t_table1.
      ENDLOOP.
      lo_nd_sflight = wd_context->get_child_node( 'DATA_TAB' ).
      lo_nd_sflight->bind_table( t_table1 ).
    Thanks,
    Shaik Shadulla.
    Edited by: shaik shadulla on Jul 16, 2009 3:27 PM

  • Uploading CSV file into internal table

    Hi,
    I want to upload a CSV file into internal table.The flat file is having values as below:
    'AAAAA','2003-10-11 07:52:37','167','Argentina',NULL,NULL,NULL,NULL,NULL,'MX1',NULL,NULL,'AAAA BBBB',NULL,NULL,NULL,'1',NULL,NULL,'AR ',NULL,NULL,NULL,'ARGENT','M1V','MX1',NULL,NULL,'F','F','F','F','F',NULL,'1',NULL,'MX','MMI ',NULL
    'jklhg','2004-06-25 08:01:57','456','hjllajsdk','MANAGUA   ',NULL,NULL,'265-5139','266-5136 al 38','MX1',NULL,NULL,'hjgkid GRÖBER','sdfsdf dfs asdfsdf 380 ad ased,','200 as ads, sfd sfd abajao y 50 m al sdf',NULL,'1',NULL,NULL,'NI ',NULL,NULL,NULL,'sdfdfg','M1V','dds',NULL,NULL,
    Here I can not even split at ',' because some of the values are having value like NULL and some have values with comma too,
    The delimiter is a quote and the separator is a comma here.
    Can anyone help on this?
    Thanks.
    Edited by: Ginger on Jun 29, 2009 9:08 AM

    As long as there can be a comma in a text literal you are right that the spilt command doesn't help. However there is one possibility how to attack this under one assumption:
    - A comma outside a text delimiter is always considered a separator
    - A comma inside a text delimiter is always considered a comma as part of the text
    You have to read you file line by line and then travel along the line string character by character and setting a flag or counter for the text delimiters:
    e.g.
    "Text","Text1, Text2",NULL,NULL,"Text"
    String Index  1: EQ " => lv_delimiter = 'X'
    String Index  2: EQ T => text literal (because lv_delimiter = 'X')
    String Index  3: EQ e => text literal (because lv_delimiter = 'X')
    String Index  4: EQ x => text literal (because lv_delimiter = 'X')
    String Index  5: EQ t => text literal (because lv_delimiter = 'X')
    String Index  6: EQ " => lv_delimiter = ' ' (because it was 'X' before)
    String Index  7: EQ , => This is a separator because lv_delimiter = ' '
    String Index  8: EQ " => lv_delimiter = 'X' (because it was ' ' before)
    String Index  9: EQ T => text literal (because lv_delimiter = 'X')
    String Index 10: EQ e => text literal (because lv_delimiter = 'X')
    String Index 11: EQ x => text literal (because lv_delimiter = 'X')
    String Index 12: EQ t => text literal (because lv_delimiter = 'X')
    String Index 13: EQ 1 => text literal (because lv_delimiter = 'X')
    String Index 14: EQ , => text literal (because lv_delimiter = 'X')
    String Index 15: EQ T => text literal (because lv_delimiter = 'X')
    Whenever you hit a 'real' separator (lv_delimiter = ' ') you pass the value of the string before that up to the previous separator into the next structure field.
    This is not an easy way to do it, but if you might have commas in your text literal and NULL values I gues it is probably the only way to go.
    Hope that helps,
    Michael

  • Uploading CSV File into Web Dynpro Java Table and Write back to a Database

    Hi Gurus!
    I would like to upload a csv file and read the content into an UI table element.
    Then, I need to write the uploaded file back to a database. I'm using NetWeaver 2004s.
    could you please provide advice for both, uploading and wirting to databse (e.g. maxDB or oracle), since I'm quite new in WDJ.
    thanks in advance.
    farid
    ps. helpfull answers will be rewarded with points!

    Hi ,
    have look at this blog
    https://www.sdn.sap.com/irj/sdn/weblogs?blog=/pub/wlg/6603. [original link is broken] [original link is broken] [original link is broken]
    Have a look at this links.
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/00062266-3aa9-2910-d485-f1088c3a4d71.
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/c0d9336b-b4cf-2910-bdbf-b00d89bd2929.
    Re: Popup Internal Window - data type IWDWindow not available
    Regards,
    krishna.

  • How to read and upload microsoft word file into database using forms9i

    Hi,
    How to read and upload microsoft word file into oracle database using forms9i. I appretiate if anyone can send me example or atleast a sujjetion.
    Thanks in advance
    Mahesh Ragineni

    The webutil package includes the ability up upload from the client to the database. See otn.oracle.com/products/forms and click on webutil for more details.
    Regards
    Grant Ronald
    Forms Product Management

  • How can upload doc file into database !!

    Dear Everyone,
    How can i upload a doc file into Mysql database ....
    can any one please give ur suggestions...
    i will show u my code
    upload.jsp
    <form name="uploader" action="uploaded.jsp"
    enctype="multipart/form-data">
      <div align="center">
      <table id="table1" border="1" bordercolor="#ff0000"
    cellpadding="0" cellspacing="0" width="50%">
        <tbody bgcolor="#c8d8f8">
          <tr>
            <td bgcolor="#ccccff">
            <p align="center">
               Resume Upload! </p>
            </td>
          </tr>
          <tr>
            <td> 
            <p align="center">You can upload your
    resume.. </p>
            <p align="center">
            <table align="center" border="1"
    cellpadding="10" cellspacing="10">
              <tbody>
                <tr>
                  <td>
                  <p><input name="file" type="file">
                  <input name="uploadButton" value="Upload"
    type="submit"></p>
                  </td>
                </tr>
              </tbody>
            </table>
            </p>
            </td>
          </tr>
        </tbody>
      </table>
      </div>
    </form>
    uploaded.jsp
    <BODY>
    <%@ page import="java.sql.*" %>
    <%@ page import="java.util.*" %>
    <%@ page import="java.io.*" %>
    <% 
        String file1=request.getParameter("file");
        int len;
        String query;
        PreparedStatement pstmt;
       int i=0;
        Class.forName("com.mysql.jdbc.Driver");
    DriverManager.getConnection("jdbc:mysql://localhost:3306    Connection conn= /employee","root","");
         try {
                File file = new File(file1);
                   if (file==null)
    %>
    <center>Nothing in It</center>
    <%
                else
                FileInputStream fis = new FileInputStream(file);
                len = (int)file.length();
                query = ("insert into loader(resume) VALUES(?)");
                pstmt = conn.prepareStatement(query);
                pstmt.setString(1,file.getName());
                pstmt.setInt(2, len);
                //method to insert a stream of bytes
                pstmt.setBinaryStream(3, fis, len);
              i=pstmt.executeUpdate();
                   if(pstmt!=null)
                 pstmt.close();
                if(conn!=null)
                 conn.close();
            } catch (Exception e) {
                e.printStackTrace();
                 if(i>0)
                        out.println("uploaded");
                    else
                        out.println("not uploaded")
    %>
    </BODY>

    File file = new File("myDoc.doc");
    FileInputStream fis = new FileInputStream(file);The file name will most likely NOT be hard-coded. I don't think the question surrounding this topic is how to do the insert statement (he/she clearly knows SQL).
    HTTP and the web browser take care of the file transfer, but the server stores the file in a temporary location. The question is, "How do I found out that location?" In PHP (I know that doesn't offer much help to you, but ...), that location is held in a variable called $_FILES. From there you can simply copy the file to a location you specify (probably with a user-specified name under a directory specifically for that user).
    I hope this is of some help:
    http://www.oop-reserch.com/mime_example_4.html
    Good Luck,
    C. R.

Maybe you are looking for

  • PDF Exports (Settings)

    Hi again, I do lots of advertising for my company. These are send to the magazines in PDF Format. I know they are a various setting for PDF files. I would like to know more about: 1) PDF Presets: a) High quality Print b) PDF/X-1A: 2001 c) PDF/X-3:200

  • [JS CS4] define a selection area

    Hi all, I have to isolate repetitive areas in documents of hundreds of pages. My intention is to select the items located in this area. I wrote a while ago a script to find an item at xy location but this time, x & y will always be different and I ca

  • Problem in data reconcilation

    Hi Experts, In the extractor 0EC_PCA_1 there are three key figure credit, debit and accumulated balance. we reconcile value of credit and debit in tcode 2kee or ke5z in R/3. Can anyone please tell how to reconcile figures of accumulated balance. Than

  • How configure a Logical System (XI) as receiver for an Outbound Idoc?

    Hi all, How can I configure a Logical System (XI) as receiver for an Outbound Idoc? Points will be given, Regards, Daniela

  • Can somebody fix my corrupted subvi, error "Fatal Internal Error" "objheap.cpp"

    Hello, I have been strugling to open this file after a reboot due to not responding computer. The file is a part a larger library however, this is the part that is not responding and giving "Fatal Internal Error" "objheap.cpp" .  Does anyone know how