1. Get rid of all advertisements and get unlimited access to documents by upgrading to Premium Membership. Upgrade to Premium Now and also get a Premium Badge!

Web adi error during upload of data

Discussion in 'Other Development Tools' started by kiran.marla, Mar 16, 2017.

  1. kiran.marla

    kiran.marla Forum Genius

    Messages:
    430
    Likes Received:
    52
    Trophy Points:
    505
    Location:
    Khammam
    Hello All,

    I have developed a custom WEB ADI from the scratch.

    My requirement is to create a package and procedure in a package.
    when i upload the data from WEB ADI spread sheet to EBS Table, the data should sit in the table through packaged procedure. Table structure is SNO - NUMBER, SNAME - VARCHAR2(100)

    Code for Package:

    Code (SQL):
    CREATE OR REPLACE PACKAGE XXCL_BASWARE_TEST_ADI_PKG AS
    PROCEDURE TEST_ADI_FUNC(P_SNO    IN NUMBER, P_SNAME IN VARCHAR2);
    END XXCL_BASWARE_TEST_ADI_PKG;
    Code (SQL):
    CREATE OR REPLACE PACKAGE BODY XXCL_BASWARE_TEST_ADI_PKG AS
    PROCEDURE TEST_ADI_FUNC(P_SNO IN NUMBER, P_SNAME IN VARCHAR2)
    IS
    BEGIN
    INSERT INTO  XXCL.XXCL_BASWARE_TEST_ADI VALUES(P_SNO, P_SNAME);
    END;
    END XXCL_BASWARE_TEST_ADI_PKG;
    and when i download the data, the data should be pulled from table and show in excel sheet.

    Through WEB ADI spread sheet, i am able to download the existing data from table . while uploading

    for SNAME , i am unable to enter values like ABC. but able to enter '00124578'. data sit directly into table without trimming leading zeros.

    I have uploaded the files, which shows 'A' values is errored out for SNAME.

    I need to enter ABC value in SNAME field.

    is there any solution to come out of the error?

    Instance details:
    EBS Version : 12.2.4
    MS-EXCEL Version : 2016.

    Help is appreciated.
     

    Attached Files:

  2. ashokgoud.e

    ashokgoud.e Active Member

    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    100
    Location:
    Hyderabad
    I saw the error in the attached Webadi error and it is showing as SQL Error, So we cannot get an exact error by seeing that message.

    Can you add an exception and use SQLERRM .So that will get the exact issue. My assumption is that there might be the data type issue.

    Sample code:
    BEGIN
    INSERT INTO XXCL.XXCL_BASWARE_TEST_ADI VALUES(P_SNO, P_SNAME);
    EXCEPTION
    WHEN OTHERS THEN
    Raise_Application_Error (-20343, 'Exception' ||SQLERRM);
    END;
     
  3. kiran.marla

    kiran.marla Forum Genius

    Messages:
    430
    Likes Received:
    52
    Trophy Points:
    505
    Location:
    Khammam
    Hi Ashok, You are absolutely correct. When I take all parameters to varchar2, then it was working fine. When I checked BNE_INTERFACE_COLS_B table, upload_param_list_item_num column has reversed number list. i.e. P_SNAME = 1, P_SNO = 2. So if i am entering value like 1,'ABC'. ... Internally 'ABC' is assigned to P_SNO, 1 is assigned to P_SNAME. In short the values are swapped. if both are maded to varchar2, then it would be fine.

    Thanks.