Please Help, problem in Excel Date.

Hi,
Currently, I am having a JBDC-ODBC connecting to an Excel file, it will read a number of data from the file and one of them is the date (formatted to month/day/year using format cell in Excel). As I need to compared the date entered in Excel with the current date, I had tried (rs.getString("Date").equalsIgnoreCase(date)) ,and converting the current date to String or Integer before comparing with the Excel data but to no avail. Hence, greatly appreciate that someone can provide me with some pointers in comparing the Excel data with the current date (using getTime()).
In addition, why can't I insert data into another sheet using the following (there is no problem in inserting into the same sheet I am reading data from):
a)     stmt.executeUpdate("INSERT INTO [sheet1$] (Data1) VALUES ('data1')");
OR
b)          uprs.moveToInsertRow();
          uprs.updateString("Data1",data1);
          uprs.insertRow();
All suggestions and advises are greatly appreciate and welcomed. Thks

I would create a Calendar object from the string you read from the Excel file. do this by creating string tokens from the result of rs.getString("Date") to represent your month day year. Then create another calendar object from your date object (or convert it or whatever) and then compare those two. Heres my code:
    Calendar deliveryDate = Calendar.getInstance();
    StringTokenizer tokens;
    int day, month, year;
    tokens = new StringTokenizer(excelDateString, "/", false);
    month = new Integer(tokens.nextToken()).intValue();
    day = new Integer(tokens.nextToken()).intValue();
    year = new Integer(tokens.nextToken()).intValue();
    deliveryDate.set(year, month, day);Re the second question, no idea sorry.
-tobes

Similar Messages

  • Premiere Pro CS5: please help problem with importing a file error output "there was an error decompressing audio or video"

    please help problem with importing a file error output "there was an error decompressing audio or video"

    this is related to what adobe program/version?

  • HT1338 I have updated my Imac to Mavericks and now my parallells won't work and I have reinstalled as per the instructions. Please help as all my data is on a hardrive that is formatted for PC

    I have updated my Imac to Mavericks and now my parallells won't work and I have reinstalled as per the instructions. Please help as all my data is on a hardrive that is formatted for PC.

    Yes I just discovered that this morning but I have purchased another external harddrive and formatted it for both and am in the process of transferring the files across it and then I will erase the old harddrive and reformat it so I can use it.
    I have learnt to format harddrives from this experience but am happy to see the back of parallells.
    Thank you for your help though it is much appreciated.

  • Please help me out with  "Data only excel option "

    Post Author: pavan pusuluri
    CA Forum: Crystal Reports
    When i am trying to spool the data with data only excel option using crystal reports XI, the records are appearing in two rows instead of single row. i have studied that when we use data only excel option entire record will be displayed in a single row,but it is not appearing in that way.Please help me out in fixing this bug. I am very much new to crytal reports.

    Post Author: pavan pusuluri
    CA Forum: Crystal Reports
    I thank you for the prompt reply.  
    All the field are of same size and height.  The format is fine.  The report is designed in such a way that data is   displayed in three detail sections. What i would like to have is " i want the data in these three sections to be displayed in a single row when i select the data only excel  export option".Please help me  out in fixing this issue.
    Thanks in anticipation

  • , please help problem downloading apps since update

    Why can't i download apps since i updated to i06, i  log in with password .am then asked for three security questions fill this out click done and get the answer timed out try again, what is causing this please help.

    Settings>General>Reset (at the far bottom)>Reset All Settings
    That will ALWAYS work for the "3 Security Questions - Timed Out problem".  No data will be lost, but your network settings will be reset.

  • Please help...excel to html

    Dear,
    I have a assignment about java. My platform is red hat linux, jsp, tomcat server. I don't know how to upload a excel file and display this in browser. The main problem is that how to convert excel file into html format or anyother method?
    that is i want to display the excel file in jsp....Can anyone help me.
    Please help me as it is very urgent. please!!
    Thanks very much
    joyce

    Work assignment or homework for school?
    joycejoyce, you're swallowing a lot here if you really are fresh to Java. Have you written any Java before taking on this assignment?
    You sound like you're in a panic. Get a good book on servlets, like Jason Hunter's O'Reilly book or Marty Hall's "Core Servlets and JSPs" and start reading a little before you jump into a POI black hole.
    No matter how desperate you are, you can't expect anybody watching this forum to just hand you a solution. You're going to have to do some work, and it's going to take time. Start reading, coding, and learning. Try to do something easy before you do something hard. Can you run Tomcat at all? Can you do a simple servlet and JSP and get them to work? That's a start. Do that before you tackle anything else.
    JMHO. - MOD

  • Please help me on the data selection - drill down

    Can any one please help me,
    I'm struggling with the data selection. I trid to finding the solution all the way but no hopes.
    see below are my data sets:
    1) from this table i have to plot piechart.
    Division Name                   Percentage
    AMESA                            1.79%
    ANZ                            1.79%
    Central                            5.36%
    Commercial                            8.93%
    Eastern Europe                   1.79%
    Greater China                     3.57%
    Italy                           10.71%
    Japan                            35.71%
    Latin America     12.50%
    Mid Atlantic/South     1.79%
    Northeast                           3.57%
    NY/NJ                           1.79%
    SE Asia                           7.14%
    TME                           3.57%
    2) this below table is having the data same as "diivsion" above and their coerponding "Product" with its counts.
    Here i want plot the bar chart with product and its counts. and also this chart should display only the products for the division selection above.
    I mean that, when the users clicks the particular "division" then the coreponding "products" should only be displayed on the bar chart.
    Division Name     Product                 Escalations
    AMESA                          CLARiiON                          1
    ANZ                 Replication Manager     1
    Central                    ControlCenter                          1
                         Open Replicator                          1
                                Symmetrix                          1
    Commercial                             CLARiiON     
                                 Disk Library                    2
                                 Celerra                         1
                                 PowerPath                         1
                                 Symmetrix                          1
    Eastern Europe         Celerra                     1
    Greater China         CLARiiON     
                               RecoverPoint     1
                                   Symmetrix     1
    Italy                               CLARiiON                          2
                                 Disk Library     1
                               Invista                         1
                                Networker                         1
                              RecoverPoint                         1
    Japan                        PowerPath     
                            CLARiiON                         5
                            Disk Library                          3
                            Symmetrix                 3
                             Celerra                         2
                    Replication Manager                  2
                         Avamar                      1
                           Centera                      1
                          Connectrix                       1
                            ControlCenter                       1
    I can't try using dynamic visibility with the pie chart and bar chart. because my dashboard is having multiple tabs so i want to use the dynamic visibility there.
    any help appreciated.
    Thanks,
    rdc422
    Edited by: rdc422 on Aug 24, 2009 12:18 PM

    Radha,
    Looks like you are still facing problem with dynamic visibility, i had sent the xlf file to your email.
    I created drill down for
    Japan
    Commercial
    Central
    Similarly you can do it for others.
    -Anil

  • In condition records section Search help problem at one data type

    hi there,
    we are upgrading 4.6c version to ecc 6.0 past january. but in
    vk11/vk12/vk13 condition master records sections, we have a problem for
    one data type search help. when we want to join sales deal code to sales
    detarmination condition, at one tables rows type price list (data type =
    pltyp_d) does not allow f4 (search help).
    thanks your interesting.
    Sinan Altıner
    Betek Boya ve Kimya Sanayi A.Ş.
    SAP CONSULTANT / ABAP Developer

    Hi surya,
    I per your suggestion i did like this ,
    data : date1 like sy-datum.
    types : w_date1 type sy-datum.
    date1 = w_date1(ztable-date1). "ztable-date1 - is screen field.
    but it is giving error "The field "W_DATE1" is unknown, but there is a field with the similar name "DATE1" . . . ."
    actually that value is coming after triggering PBO event but i want that value in at time of calling F4 help at that screen filed
    suppose on screen the fields like
    date : 30.08.2008.
    matnr : ( .............F4 )  '".....on this field when i m pressing F4 that time only that above date materials should come as per my first query see my first thread.
    thanks,
    Sanket.

  • Please help: problem configuring a SQL server datasource in Websphere.

    I am using Rational Developer 6 and its integrated testing server (websphere v6). When configuring a data source for SQL server, I did the following steps in admin console of the test server:
    1. Created a JDBC provider, using WebSphere embedded ConnectJDBC driver for MS SQL Server;
    2. Created a datasource under the previously created JDBC provider, filled in the server name, DB name and port number (1433 for SQL server);
    3. Created a J2C authentication alias that has the login info of SQL server;
    4. Assigned the created J2C alias to both component and container managed authentication alias;
    However, when I click "Test Connection", it always gets back to me with an error "java.lang.Exception: java.sql.SQLException: [IBM][SQLServer JDBC Driver]Error establishing socket. Connection refused: connectDSRA0010E: SQL State = 08001, Error Code = 0.".
    My ultimate goal is to configure a SQL server datasource so that I can configure Kodo to use this datasource.
    Can some one please help? Thanks in advance.

    Try this:
    http://www-1.ibm.com/support/docview.wss?uid=swg21210871
    I am yet to test this. I am going to download latest SP for SQL Server 2000 and install it. I hope it will do the magic.

  • Please help me in inserting data into table from XML message.

    Hi Experts,
    Please provide a procedure to implement my below requirement.
    Since I am new to queue concept.
    [code]- <MESSAGES>
    - <MESSAGE ID="3026900">
      <MSG_ID>3026900</MSG_ID>
      <DT_POSTED>6/20/2013 08:15:48</DT_POSTED>
      <POSTED_BY>GPD_MSG_EXTRACTOR</POSTED_BY>
      <DT_LAST_QUEUED />
    - <MSG>
    - <WORK_SET TRANSACTION_ID="@TRANS_ID" TRANSACTION_TYPE="Batch" IS_ACID="@IS_ACID">
    - <WORK_UNIT GROUP="LEAD_TIME" ACTION="UPDATE" AFFECTED="LEAD_TIME">
    - <RECORDSET TABLE_NAME="LEAD_TIME">
    - <xml xmlns:s="uuid:BDC6E3F0-6DA3-11d1-A2A3-00AA00C14882" xmlns:dt="uuid:C2F41010-65B3-11d1-A29F-00AA00C14882" xmlns:rs="urn:schemas-microsoft-com:rowset" xmlns:z="#RowsetSchema">
    - <rs:data>
      <z:row business_unit_id="3838" geo="AT" sku="A0814818" dw_maint_flag="False" stock_status_id="0" lead_time="30" est_qty="0" leadtime_lock="False" update_dts="2013-06-12T02:08:30.367" update_uid="DEACTIVATE_SKU_PROCESS" leadtime_dts="2010-05-22T02:21:21.707" leadtime_uid="Lead_Time_Rules" />
      <z:row business_unit_id="202" geo="GB" sku="A0814819" dw_maint_flag="False" stock_status_id="0" lead_time="30" est_qty="0" leadtime_lock="False" update_dts="2013-06-12T02:08:30.367" update_uid="DEACTIVATE_SKU_PROCESS" leadtime_dts="2010-05-22T02:21:21.707" leadtime_uid="Lead_Time_Rules" />
      <z:row business_unit_id="2828" geo="BE" sku="A0814820" dw_maint_flag="False" stock_status_id="0" lead_time="30" est_qty="0" leadtime_lock="False" update_dts="2013-06-12T02:08:30.367" update_uid="DEACTIVATE_SKU_PROCESS" leadtime_dts="2010-05-22T02:21:21.707" leadtime_uid="Lead_Time_Rules" />
      </rs:data>
      </xml>
      </RECORDSET>
      </WORK_UNIT>
    - <WORK_UNIT GROUP="LEAD_TIME" ACTION="ADD" AFFECTED="LEAD_TIME">
    - <RECORDSET TABLE_NAME="LEAD_TIME">
    - <xml xmlns:s="uuid:BDC6E3F0-6DA3-11d1-A2A3-00AA00C14882" xmlns:dt="uuid:C2F41010-65B3-11d1-A29F-00AA00C14882" xmlns:rs="urn:schemas-microsoft-com:rowset" xmlns:z="#RowsetSchema">
    - <rs:data>
      <z:row business_unit_id="202" geo="GB" sku="A0814821" dw_maint_flag="False" stock_status_id="0" lead_time="30" est_qty="0" leadtime_lock="False" update_dts="2013-06-12T02:08:30.367" update_uid="DEACTIVATE_SKU_PROCESS" leadtime_dts="2010-05-22T02:21:21.707" leadtime_uid="Lead_Time_Rules" />
      <z:row business_unit_id="2828" geo="BE" sku="A0814822" dw_maint_flag="False" stock_status_id="0" lead_time="30" est_qty="0" leadtime_lock="False" update_dts="2013-06-12T02:08:30.367" update_uid="DEACTIVATE_SKU_PROCESS" leadtime_dts="2010-05-22T02:21:21.707" leadtime_uid="Lead_Time_Rules" />
      </rs:data>
      </xml>
      </RECORDSET>
      </WORK_UNIT>
    - <WORK_UNIT GROUP="LEAD_TIME" ACTION="DELETE" AFFECTED="LEAD_TIME">
    - <RECORDSET TABLE_NAME="LEAD_TIME">
    - <xml xmlns:s="uuid:BDC6E3F0-6DA3-11d1-A2A3-00AA00C14882" xmlns:dt="uuid:C2F41010-65B3-11d1-A29F-00AA00C14882" xmlns:rs="urn:schemas-microsoft-com:rowset" xmlns:z="#RowsetSchema">
    - <rs:data>
      <z:row business_unit_id="202" geo="GB" sku="A0814817" dw_maint_flag="False" stock_status_id="0" lead_time="30" est_qty="0" leadtime_lock="False" update_dts="2013-06-12T02:08:30.367" update_uid="DEACTIVATE_SKU_PROCESS" leadtime_dts="2010-05-22T02:21:21.707" leadtime_uid="Lead_Time_Rules" />
      <z:row business_unit_id="2828" geo="BE" sku="A0814816" dw_maint_flag="False" stock_status_id="0" lead_time="30" est_qty="0" leadtime_lock="False" update_dts="2013-06-12T02:08:30.367" update_uid="DEACTIVATE_SKU_PROCESS" leadtime_dts="2010-05-22T02:21:21.707" leadtime_uid="Lead_Time_Rules" />
      </rs:data>
      </xml>
      </RECORDSET>
      </WORK_UNIT>
      </WORK_SET>
      </MSG>
      </MESSAGE>
      </MESSAGES>[/code]
    The above XML message is receieved by our oracle queue.Once the message is receieved to our queue.
    We have to process the message according to the action(UPDATE ADD DELETE).
    From this message we have to process only 3 fields (geo  sku lead_time).
    These three feilds data should be processed into the SKU_LEAD_TIME table based on the action.
    Req1:
    IF the action is update then the records should be updated in the "LEAD_TIME_TABLE" table
    IF the action is update then the records should be updated in the "LEAD_TIME_TABLE" table
    based on the below condition.
    [code]UPDATE LEAD_TIME_TABLE SET lead_time= lead time from xml message
    WHERE LEAD_TIME_TABLE.SKU=sku from xml message AND LEAD_TIME_TABLE.GEO=geo from xml message;[/code]
    Req2:
    IF the action is delete then the records should be deleted from the "LEAD_TIME_TABLE" table.
    based on the below condition.
    [code]DELETE FROM LEAD_TIME_TABLE
    WHERE LEAD_TIME_TABLE.SKU=sku from xml message AND LEAD_TIME_TABLE.GEO=geo from xml message;[/code]
    Req3:
    IF the action is add then the records should be inserted in the "LEAD_TIME_TABLE"  and "LEAD_TIME_TABLE_STAGING" table
    based on the below conditions.
    Req3.1:
    If SKU from XML message is available in "SKU_TABLE" table
    then the three parameter(GEO SKU LEAD_TIME) values from XML message should be inserted into "LEAD_TIME_TABLE" table.
    Req3.2:
    If SKU from XML message is not available in "SKU_TABLE" table
    then the three parameter(GEO SKU LEAD_TIME) values from XML message should be inserted into "LEAD_TIME_TABLE_STAGING" table.
    Req3.3:
    Once the new SKU is avilable in "SKU_TABLE" table then the corresponding SKU record should be
    inserted into "LEAD_TIME_TABLE" table and that record should be deleted from  "LEAD_TIME_TABLE_STAGING" table.
    I am posting required scripts and test cases.
    [code]CREATE TABLE LEAD_TIME_TABLE(sku VARCHAR2(20),model VARCHAR2(20),class CHAR(1),geo VARCHAR2(6),lead_time NUMBER,created DATE);
    CREATE TABLE LEAD_TIME_TABLE_STAGING(sku VARCHAR2(20),geo VARCHAR2(6),lead_time NUMBER);
    CREATE TABLE SKU_TABLE(sku VARCHAR2(20),geo VARCHAR2(6),lead_time NUMBER);
    INSERT INTO SKU_TABLE VALUES('A0814817','GB',30);
    INSERT INTO SKU_TABLE VALUES('A0814818','AT',30);
    INSERT INTO SKU_TABLE VALUES('A0814819','GB',30);
    INSERT INTO SKU_TABLE VALUES('A0814820','BE',30);
    INSERT INTO SKU_TABLE VALUES('A0814821','GB',30);
    INSERT INTO LEAD_TIME_TABLE(SKU,GEO,LEAD_TIME) VALUES('A0814817','GB',30);
    INSERT INTO LEAD_TIME_TABLE(SKU,GEO,LEAD_TIME) VALUES('A0814818','AT',20);
    INSERT INTO LEAD_TIME_TABLE(SKU,GEO,LEAD_TIME) VALUES('A0814819','GB',20);
    INSERT INTO LEAD_TIME_TABLE(SKU,GEO,LEAD_TIME) VALUES('A0814820','BE',20);
    INSERT INTO LEAD_TIME_TABLE_STAGING VALUES('A0814822','BE',30);[/code]
    From the above message.
    Test case for req3.1:
    The action for SKU numbers "A0814821"  "A0814822" are insert.
    The SKU number  "A0814821" is available in SKU_TABLE table.
    so the record should be inserted in the LEAD_TIME_TABLE.
    [code]SELECT * FROM LEAD_TIME_TABLE;
    SKU        GEO   LEAD_TIME
    A0814817    GB    30
    A0814818    AT    20
    A0814819    GB    20
    A0814820    BE    20
    A0814821    GB    30[/code]
    Test case for req3.2:
    The action for SKU numbers "A0814821"  "A0814822" are insert.
    The SKU number  "A0814822" is not available in SKU_TABLE table.
    so the record should be inserted in the LEAD_TIME_TABLE_STAGING.
    [code]SELECT * FROM LEAD_TIME_TABLE_STAGING;
    SKU        GEO   LEAD_TIME
    A0814822    BE     30[/code]
    Test case for req3.3:
    The action for SKU numbers "A0814821"  "A0814822" are insert.
    The SKU number  "A0814822" is not available in SKU_TABLE table.
    Once I insert SKU number "A0814822" in SKU_TABLE table.
    The corresponding records automatically should be inserted in the LEAD_TIME_TABLE
    and should be deleted from LEAD_TIME_TABLE_STAGING.
    [code]SELECT * FROM LEAD_TIME_TABLE_STAGING;  --- should return NULL.
    SELECT * FROM LEAD_TIME_TABLE;
    SKU        GEO   LEAD_TIME
    A0814817    GB    30
    A0814818    AT    20
    A0814819    GB    20
    A0814820    BE    20
    A0814821    GB    30
    A0814822    BE    30[/code]
    Please help me.
    Thanks in advance.

    Hi,
    I have resolved this issue.
    But I have stuck up in implementing some of the scenarios.
    Req1:
    IF the action is update then the records should be updated in the "LEAD_TIME_TABLE" table
    IF the action is update then the records should be updated in the "LEAD_TIME_TABLE" table
    based on the below condition.
    UPDATE LEAD_TIME_TABLE SET lead_time= lead time from xml message
    WHERE LEAD_TIME_TABLE.SKU=sku from xml message AND LEAD_TIME_TABLE.GEO=geo from xml message;
    Req3:
    IF the action is add then the records should be inserted in the "LEAD_TIME_TABLE"  and "LEAD_TIME_TABLE_STAGING" table
    based on the below conditions.
    Req3.1:
    If SKU from XML message is available in "schema_name.SKU_TABLE" table.
    The schema_name.SKU_TABLE table should be selected based on "business_unit_id" of XML message and "sid" of MAPPING table WHERE business_unit_id=sid.
    then the three parameter(GEO SKU LEAD_TIME) values from XML message and two fields MODEL,CLASS from SKU_TABLE
    should be inserted into "LEAD_TIME_TABLE" table.
    Req3.2:
    If SKU from XML message is not available in "schema_name.SKU_TABLE" table
    The schema_name.SKU_TABLE table should be selected based on "business_unit_id" of XML message and "sid" of MAPPING table WHERE business_unit_id=sid.
    then the four parameter(BUSINESS_UNIT_ID GEO SKU LEAD_TIME) values from XML message
    should be inserted into "LEAD_TIME_TABLE_STAGING" table.
    Req3.3:
    Once the new SKU is avilable in "schema_name.SKU_TABLE" table then the corresponding SKU record should be
    inserted into "LEAD_TIME_TABLE" table and that record should be deleted from  "LEAD_TIME_TABLE_STAGING" table.
    The schema_name.SKU_TABLE table should be selected based on "business_unit_id" of LEAD_TIME_TABLE_STAGING and "sid" of MAPPING table WHERE business_unit_id=sid.
    I am posting required scripts and test cases.
    [code]CREATE TABLE LEAD_TIME_TABLE(sku VARCHAR2(20),model VARCHAR2(20),class CHAR(1),geo VARCHAR2(6),lead_time NUMBER,created DATE);
    CREATE TABLE LEAD_TIME_TABLE_STAGING(business_unit_id NUMBER,sku VARCHAR2(20),geo VARCHAR2(6),lead_time NUMBER);
    CREATE TABLE SKU_TABLE(sku VARCHAR2(20),model VARCHAR2(20),class VARCHAR2(10));
    CREATE TABLE mapping(sid NUMBER,schema_name VARCHAR2(20));
    INSERT INTO LEAD_TIME_TABLE(SKU,GEO,LEAD_TIME) VALUES('A0814817','GB',30);
    INSERT INTO LEAD_TIME_TABLE(SKU,GEO,LEAD_TIME) VALUES('A0814818','AT',20);
    INSERT INTO LEAD_TIME_TABLE(SKU,GEO,LEAD_TIME) VALUES('A0814819','GB',20);
    INSERT INTO LEAD_TIME_TABLE(SKU,GEO,LEAD_TIME) VALUES('A0814820','BE',20);
    INSERT INTO SKU_TABLE VALUES('A0814817','M125','C111');
    INSERT INTO SKU_TABLE VALUES('A0814818','M127','A111');
    INSERT INTO SKU_TABLE VALUES('A0814819','M126','A111');
    INSERT INTO SKU_TABLE VALUES('A0814820','N100','B111');
    INSERT INTO SKU_TABLE VALUES('A0814821','P123','B111');
    INSERT INTO mapping VALUES(202,'WEDB');
    INSERT INTO mapping VALUES(2828,'HR');
    INSERT INTO mapping VALUES(3838,'BB');
    [/code]
    Test case for req3.1:
    The action for SKU numbers "A0814821"  "A0814822" are insert.
    The SKU number  "A0814821" is available in schema_name.SKU_TABLE table.
    so the record should be inserted in the LEAD_TIME_TABLE.
    [code]SELECT * FROM LEAD_TIME_TABLE;
    SKU        MODEL  CLASS  GEO   LEAD_TIME
    A0814817    M125   C111   GB     30
    A0814818    M127   A111   AT     20
    A0814819    M126   A111   GB     20
    A0814820    N100   B111   BE     20
    A0814821    P123   B111   GB     30
    [/code]
    Test case for req3.2:
    The action for SKU numbers "A0814821"  "A0814822" are insert.
    The SKU number  "A0814822" is not available in SKU_TABLE table.
    so the record should be inserted in the LEAD_TIME_TABLE_STAGING.
    [code]SELECT * FROM LEAD_TIME_TABLE_STAGING;
    BUSINESS_UNIT_ID       SKU        GEO   LEAD_TIME
    2828               A0814822    BE     30[/code]
    Test case3.3.3:
    The action for SKU numbers "A0814821"  "A0814822" are insert.
    The SKU number  "A0814822" is not available in SKU_TABLE table.
    Once I insert SKU number "A0814822" in SKU_TABLE table.
    The corresponding records automatically should be inserted in the LEAD_TIME_TABLE
    and should be deleted from LEAD_TIME_TABLE_STAGING.
    [code]INSERT INTO SKU_TABLE VALUES('A0814822','P123','B111');
    SELECT * FROM LEAD_TIME_TABLE_STAGING;  --- should return NULL.
    SELECT * FROM LEAD_TIME_TABLE;
    SKU        MODEL  CLASS  GEO   LEAD_TIME
    A0814817    M125   C111   GB     30
    A0814818    M127   A111   AT     20
    A0814819    M126   A111   GB     20
    A0814820    N100   B111   BE     20
    A0814821    P123   B111   GB     30
    A0814822    P123   B111   GB     30[/code]
    I am able to implement Req1 and Req3.1 for action UPDATE and INSERT in single merge statement.
    However my code is not taking care of all my requirements.
    Please find my below code.
    [code]   CREATE OR REPLACE PACKAGE BODY messg_values_process
       AS
        procedure ProcessInboundLtimeMessage(p_xml_message XmlType)
        is
        begin
            for work_unit in (
                select message.MESSAGE_ID
                     , work_unit.ACTION
                     , work_unit.LEADTIME_NODES
                  from XmlTable(
                        '/MESSAGES/MESSAGE'
                        passing p_xml_message
                        columns
                            MESSAGE_NO          for ordinality
                          , MESSAGE_ID          number path '@ID'
                          , WORK_UNIT_NODES     XmlType path 'MSG/WORK_SET/WORK_UNIT'
                       ) message
                     , XmlTable(
                        XmlNamespaces(
                            'urn:schemas-microsoft-com:rowset' as "rs"
                          , '#RowsetSchema' as "z"
                        '/WORK_UNIT'
                        passing message.WORK_UNIT_NODES
                        columns
                            WORK_UNIT_NO        for ordinality
                          , ACTION              varchar2(10 char) path '@ACTION'
                          , LEADTIME_NODES       XmlType path 'RECORDSET[@TABLE_NAME="LEAD_TIME"]/xml/rs:data/z:row'
                       ) work_unit
        LOOP
                CASE work_unit.ACTION
                  WHEN 'ADD'    THEN MergeData(work_unit.LEADTIME_NODES);
                  WHEN 'UPDATE' THEN MergeData(work_unit.LEADTIME_NODES);
                  WHEN 'DELETE' THEN RemoveData(work_unit.LEADTIME_NODES);
                  ELSE null;
                END CASE;
            END LOOP;
        END ProcessInboundLtimeMessage;
            procedure MergeData(p_leadtime_nodes XmlType)
        is
        begin
            if (p_leadtime_nodes is not null) then
                merge into LEAD_TIME_TABLE old
                using(
                    select *
                      from XmlTable(
                            XmlNamespaces(
                                'urn:schemas-microsoft-com:rowset' as "rs"
                              , '#RowsetSchema' as "z"
                            '/z:row[not(@business_unit_id=following-sibling::z:row/@business_unit_id)]'
                            passing p_leadtime_nodes
                            columns
                                ITEM_NO             for ordinality
                              , BUSINESS_UNIT_ID    number path '@business_unit_id'
                              , GEO                 varchar2(20 char) path '@geo'
                              , SKU                 varchar2(20 char) path '@sku'
                              , LEAD_TIME           number path '@lead_time'
                ) NEW
                   ON (old.VK_UNIT = new.SKU
                  AND old.GEO=new.GEO)
                when matched then update
                   set old.LEAD_TIME = new.LEAD_TIME
                when not matched then INSERT
                     ( old.VK_UNIT
                     , old.MODEL
                     , old.CLASS
                     , old.GEO
                     , old.LEAD_TIME
                     , old.COUNTDOWN
                     , old.LAST_UPDATED_DATE
                     values
                     ( new.SKU
                     ,'A123'
                     ,'A1234'
                     , new.GEO
                     , new.LEAD_TIME
                     , 'N'
                     , sysdate
            end if;
             exception
            when others then
                LogDataError(
                    'MergeData Procedure Failed #: '||chr(10)||sqlerrm
                  , null
                  , null
        END MergeData;
    END messg_values_process;
    /[/code]
    Please help me.
    Thanks.

  • Please Help --Export to excel time out issue

    500 Connection timed out
    Hi Friends,
    We have a query which runs about 3 minutes on web and  brings bach 54000 rows  , but when the user tries to export to excel It give timeout error as below.
    Connection timed out (-5)
    Error: -5
    Version: 6020
    Component: ICM
    Module: icxxthr_mt.c
    Line: 2467
    Server: tepas0_abc_00
    Detail: Connection to partner timed out
    Please help me out.
    Thanks a lot!

    Hi,
    Check the info here:
    https://forums.sdn.sap.com/click.jspa?searchID=5203764&messageID=959490
    There are also a lot of other threads on time out issue...
    Hope this helps...

  • Help with Importing Excel Data into Formatted Tables

    This is my first post, here, so please be gentle!
    I am a relatively new user of InDesign CS4, and I am creating a 70-pg manufacturer's price book.  A very large portion of each page is going to be size and price information imported from a large Excel spreadsheet.
    I have created the table format that I'd like to use for each page, but the trouble comes when I import the Excel data into that table.  For some reason, when I import, it all dumps into one cell.  Would it be best to import as an unformatted table, and then format the table each time, or is there a way to simply import the data into my pre-formatted table?  I've seen how the former is done, but the latter seems much easier (...although that could be my inexperience talking).
    Any advice would be greatly appreciated!
    Thanks so much,
    Laura (V1500)

    Thank you both so much for your time!  This is exactly what I needed.
    Cheers
    Laura

  • Please help - problems with iPod Nano

    I saw a page in my Popular Science magazine and it had iPod Linux. So I went to the website installed it, and it worked!!! But the problem is , is that when I plug it in to my computer, it charges but won't show up as a drive. Please help!!!!!!!!!!!!!

    Even within the iPod Linux Project the Fifth Generation iPod and the Nano are unsupported hardware so you are pretty much on you own, however check these links out:
    iPod Linux Unsupported - What if Something Goes Wrong
    iPod Linux Project- My iPod is really messed up, how can I fix it?

  • Please Help: Problems w/Frames and Rollovers

    I've been having a problem recently w/making rollovers in
    Fireworks 8. Whenever I change the color of the text (intended to
    be made into a rollover link) in one frame, it changes the color of
    that text in all of the frames. I've never had this happen in the
    previous software version. Please help! Thanks!

    PSparky wrote:
    > I've been having a problem recently w/making rollovers
    in Fireworks 8. Whenever
    > I change the color of the text (intended to be made into
    a rollover link) in
    > one frame, it changes the color of that text in all of
    the frames. I've never
    > had this happen in the previous software version. Please
    help! Thanks!
    Make sure that Share Across Layers, and Share Across Frames
    are unchecked.
    Linda Rathgeber [PVII] *Adobe Community Expert-Fireworks*
    http://www.projectseven.com
    Fireworks Newsgroup:
    news://forums.projectseven.com/fireworks/
    CSS Newsgroup: news://forums.projectseven.com/css/
    http://www.adobe.com/communities/experts/

  • Please help, problems running recovery

    hi, i have a satellite P755-S5262 RUNNING WINDOWS 7 64BIT WITH AN i7 PROCESSOR
    when i first got my laptop i was having some minor problems with it so i did a restore from the harddrive and that fixed things up. i made some recovery media and the went about setting it up, the made a backup with nere back it up 11.  later on more problems and i tried to restore from nero back up and backup didn't work so i tried recovery and it won't recover from the hard drive but my recoverey media worked and everything was fine.  so one late sleepy night 
    i triede to install some free software which didn't work so i uninstalled it using REvo uninstall and made a bad mistake, windows would not boot. most of the repair options, including toshiba recovery were not coming up.
    i had my media but after inserting disc one it said files were loading and the nothing happened.  anyway i finally got
    recoverey to come up but after choosing out of box recovery with partitions the same i got thew message preparing partitiuons and the error 08-0E89-0000 PARTITION preperation failed
    please help!

    If the problem is with the recovery media, ordering replacement recovery media might be able to help.
    If that doesn't work, it could be a failing hard drive.
    - Peter

Maybe you are looking for

  • Logical standby database problem

    i have setup logical standby database on my pc . Everything was working fine . Logs were applied. But i tried testing few things on standby and issued few commands on that. After that the logs were not applied. i tried to restart that also dint work.

  • Web based or web enabled

    Hi, Lot of our clients are requesting us to give them information regarding if we are web-based or web-enabled. My question is 1. If I am using oracle forms/reports/discoverer 10g and running it over the web with Oracle application server is that web

  • LE7 settings Enigma (M-Audio Ozonic)

    Is there somebody who want to share or know about a user bank to load into the Enigma software to get good settings for LE7 in the M-audio Ozonic soundcard/controller. Thanks /Craft

  • Diasble field in infotype

    Hi all,          I have created custom info type and its working properly, but problem is that,when user first time create record in pa30 all fields shud enable for him, but in a cahnge mode some fields should disable for him. pls help me how can i d

  • Expected "else", etc. but found "on".

    I'm trying to make an app in Applescript, and then this happened: display dialog "What version of Minecraft do you have?" buttons {"-1.5", "1.6+", "Cancel"} with icon note if the button returned of the result is "-1.5" then display dialog "Opening th