Switch doest not evaluate the switch conditions

Hello again,
I have the following, fine working, switch condition:
<case condition="bpws:getVariableData('name') = 'aktiv'">
Some lines later within the same source, I have the following, not working, switch condition:
<case condition="bpws:getVariableData('lieferrichtung') = 'ABS'">
or
<case condition="bpws:getVariableData('lieferrichtung') = 'BEZ'">
The variable types are in both cases xsd:string (SimpleType), and the variables are local to a scope.
Here a "printout" from the variable "lieferrichtung" while runtime:
<lieferrichtung>BEZ</lieferrichtung>
or
<lieferrichtung>ABS</lieferrichtung>
What's wrong?
Best regards
Harald
For anyone who can not believe my question, here are the sources:
<switch name="prüfeZustandsnamen">
<case condition="bpws:getVariableData('name') = 'aktiv'">
<bpelx:annotation>
<bpelx:pattern>NameIsAktiv</bpelx:pattern>
</bpelx:annotation>
<assign name="getZustandOid">
<copy>
<from expression="concat('/ns1:getZustaendeResponse/ns1:getZustaendeReturn[', bpws:getVariableData('iterator'), ']/ns19:OID')"/>
<to variable="xpath"/>
</copy>
<copy>
<from expression="bpws:getVariableData('getZustaende_getZustaende_OutputVariable','parameters',bpws:getVariableData('xpath'))"/>
<to variable="zustandOid"/>
</copy>
<copy>
<from variable="count"/>
<to variable="iterator"/>
</copy>
</assign>
</case>
<otherwise/>
</switch>
<switch name="prüfeLieferrichtung">
<case condition="bpws:getVariableData('lieferrichtung') = 'ABS'">
<bpelx:annotation>
<bpelx:pattern>isAbsatz</bpelx:pattern>
</bpelx:annotation>
<sequence name="Sequence_13">
<assign name="setSchlüsselMitBkVES">
<copy>
<from expression="concat('11XVE-SALES----7 ', bpws:getVariableData('getVertragsbezeichnungFromMasterDB_getVertragsinfoFromMasterDB_OutputVariable','getVertragsinfoFromMasterDBOutputCollection','/ns16:getVertragsinfoFromMasterDBOutputCollection/ns16:getVertragsinfoFromMasterDBOutput/ns16:text'))"/>
<to variable="saveEingangsgrösse_saveEingangsgroesse_InputVariable"
part="parameters"
query="/ns1:saveEingangsgroesse/ns1:pEWSVersionen/ns26:schluessel"/>
</copy>
</assign>
<invoke name="saveEingangsgrösse"
partnerLink="ecas"
portType="ns1:EWebService"
operation="saveEingangsgroesse"
inputVariable="saveEingangsgrösse_saveEingangsgroesse_InputVariable"
outputVariable="saveEingangsgrösse_saveEingangsgroesse_OutputVariable"
bpelx:inputHeaderVariable="customSoapHeaderIn"/>
</sequence>
</case>
<case condition="bpws:getVariableData('lieferrichtung') = 'BEZ'">
<bpelx:annotation>
<bpelx:pattern>isBezug</bpelx:pattern>
</bpelx:annotation>
<sequence name="Sequence_12">
<assign name="setSchlüsselMitBkKunde">
<copy>
<from expression="concat('Anderer BK ', bpws:getVariableData('getVertragsbezeichnungFromMasterDB_getVertragsinfoFromMasterDB_OutputVariable','getVertragsinfoFromMasterDBOutputCollection','/ns16:getVertragsinfoFromMasterDBOutputCollection/ns16:getVertragsinfoFromMasterDBOutput/ns16:text'))"/>
<to variable="saveEingangsgrösse_saveEingangsgroesse_InputVariable"
part="parameters"
query="/ns1:saveEingangsgroesse/ns1:pEWSVersionen/ns26:schluessel"/>
</copy>
</assign>
<invoke name="saveEingangsgrösse"
partnerLink="ecas"
portType="ns1:EWebService"
operation="saveEingangsgroesse"
inputVariable="saveEingangsgrösse_saveEingangsgroesse_InputVariable"
outputVariable="saveEingangsgrösse_saveEingangsgroesse_OutputVariable"
bpelx:inputHeaderVariable="customSoapHeaderIn"/>
</sequence>
</case>
<otherwise/>
</switch>
Message was edited by:
user570114

"lieferrichtung" is a scope local simple type variable... (The dots in the following lines are a placeholder for other activities)
<scope name="setEingangsgrössen">
<variables>
<variable name="gueltigBis" type="xsd:string"/>
<variable name="lieferrichtung" type="xsd:string"/>
</variables>
<sequence name="Sequence_10">
<while name="While_4"
condition="bpws:getVariableData('iterator') &lt;= bpws:getVariableData('count')">
<sequence name="Sequence_11">
<assign name="setSwitchParameter">
<copy>
<from expression="concat('/ns1:searchEingangsgroesseResponse/ns1:searchEingangsgroesseReturn[position()=', bpws:getVariableData('iterator'), ']/ns26:name')"/>
<to variable="xpath"/>
</copy>
<copy>
<from expression="bpws:getVariableData('getEingangsgrössen_searchEingangsgroesse_OutputVariable','parameters',bpws:getVariableData('xpath'))"/>
<to variable="lieferrichtung"/>
</copy>
<copy>
<from expression="substring(bpws:getVariableData('lieferrichtung'), string-length(bpws:getVariableData('lieferrichtung')) - 3)"/>
<to variable="lieferrichtung"/>
</copy>
</assign>
<switch name="prüfeLieferrichtung">
<case condition="bpws:getVariableData('lieferrichtung') = 'ABS'">
<bpelx:annotation>
<bpelx:pattern>isAbsatz</bpelx:pattern>
</bpelx:annotation>
<sequence name="Sequence_13">
<assign name="setSchlüsselMitBkVES">
<copy>
<from expression="concat('11XVE-SALES----7 ', bpws:getVariableData('getVertragsbezeichnungFromMasterDB_getVertragsinfoFromMasterDB_OutputVariable','getVertragsinfoFromMasterDBOutputCollection','/ns16:getVertragsinfoFromMasterDBOutputCollection/ns16:getVertragsinfoFromMasterDBOutput/ns16:text'))"/>
<to variable="saveEingangsgrösse_saveEingangsgroesse_InputVariable"
part="parameters"
query="/ns1:saveEingangsgroesse/ns1:pEWSVersionen/ns26:schluessel"/>
</copy>
</assign>
<invoke name="saveEingangsgrösse"
partnerLink="ecas"
portType="ns1:EWebService"
operation="saveEingangsgroesse"
inputVariable="saveEingangsgrösse_saveEingangsgroesse_InputVariable"
outputVariable="saveEingangsgrösse_saveEingangsgroesse_OutputVariable"
bpelx:inputHeaderVariable="customSoapHeaderIn"/>
</sequence>
</case>
<case condition="bpws:getVariableData('lieferrichtung') = 'BEZ'">
<bpelx:annotation>
<bpelx:pattern>isBezug</bpelx:pattern>
</bpelx:annotation>
<sequence name="Sequence_12">
<assign name="setSchlüsselMitBkKunde">
<copy>
<from expression="concat('Anderer BK ', bpws:getVariableData('getVertragsbezeichnungFromMasterDB_getVertragsinfoFromMasterDB_OutputVariable','getVertragsinfoFromMasterDBOutputCollection','/ns16:getVertragsinfoFromMasterDBOutputCollection/ns16:getVertragsinfoFromMasterDBOutput/ns16:text'))"/>
<to variable="saveEingangsgrösse_saveEingangsgroesse_InputVariable"
part="parameters"
query="/ns1:saveEingangsgroesse/ns1:pEWSVersionen/ns26:schluessel"/>
</copy>
</assign>
<invoke name="saveEingangsgrösse"
partnerLink="ecas"
portType="ns1:EWebService"
operation="saveEingangsgroesse"
inputVariable="saveEingangsgrösse_saveEingangsgroesse_InputVariable"
outputVariable="saveEingangsgrösse_saveEingangsgroesse_OutputVariable"
bpelx:inputHeaderVariable="customSoapHeaderIn"/>
</sequence>
</case>
<otherwise/>
</switch>
<assign name="incrementIterator">
<copy>
<from expression="bpws:getVariableData('iterator') + 1"/>
<to variable="iterator"/>
</copy>
</assign>
</sequence>
</while>
</sequence>
</scope>

Similar Messages

  • How to evaluate the dynamic condition string in PL/SQL ?

    Hello, I am solving the issue of checking and validating the event table.
    For Example, the event table namely "Contract_validated" contains some atts about a contract as follow:
    CONTRACT_VALIDATED (SEQ_ID, CO_ID, VALID_T, CHANGE_KEY, ATT1, ATT1_FROM, ATT2, ATT2_FROM, REASON, CHANGE_KEY_ORIG, ATT1_ORIG, ATT2_ORIG)
    In this table, the pairs (ATT1 and ATT1_FROM), (ATT2 and ATT2_FROM) must be compared to check whether the values are changed or not in the update event (change_key = U). If some records have change_key = U but the values does not change, I need to protocol and correct such records.
    The table name and attributes list could be dynamic, and will be provided as parameters. Therefore, I use Dynamic PL/SQL to generate the code to test the conditions between the values between the pairs columns for detecting the invalid event. However, I am stucking in testing the condition phrases because I can not evaluate the condition string in the SELECT statement. I can not use IF because parts of this condition string take the value from a record and collection type. Anyone has the idea how to evaluate the condition in such case, please give me instructions or recommendations (it could be other alternatives to solve the problems)
    Here is the code which generated from my Dynamic PL/SQL string, however, Oracle raise exception error at the EXECUTE IMMEDIATE v_sql command
    SELECT 'x' FROM DUAL WHERE (NVL(v_rec.ATT1, NULL) <> NVL(v_rec.ATT1_FROM , NULL) OR (NVL(v_rec.ATT2, NULL) <> NVL(v_rec.ATT2_FROM , NULL))
    E-0008: Unkown Exception raised in Loop. ORACLE:ORA-00904: "V_REC"."ATT2_FROM": invalid identifier
    vo_traced_list has type Table of VARCHAR2(2000), storing the atts list of table (CONTRACT_VALIDATED), it has value already from other procedure invocation.
    Here is the dynmic PL/SQL code generated dynamically depends on the table name, and attr list:
    DECLARE v_rec CONTRACT_VALIDATED%ROWTYPE;
    TYPE cv_type IS REF CURSOR;
    v_rec_cv CV_TYPE;
    v_cond VARCHAR2(4000);
    cond BOOLEAN := FALSE;
    v_exec VARCHAR2(1000);
    v_default VARCHAR2(10):= 'NULL';
    tk_val CONTRACT_VALIDATED.VALID_T%TYPE;
    pk_val CONTRACT_VALIDATED.CO_ID%TYPE;
    v_cnt NUMBER;
    BEGIN
    OPEN v_rec_cv FOR SELECT /*+ parallel(x,4) */ x.* FROM CONTRACT_VALIDATED x WHERE CHANGE_KEY = 'U' ORDER BY VALID_T;
    FETCH v_rec_cv INTO v_rec;
    IF v_rec_cv%NOTFOUND THEN
    Add_Log('Event_Validating',v_user,v_event_validated,'INFO','I-0001: No-Procession needed');
    ELSE
    BEGIN
    LOOP
    pk_val := v_rec.co_id;
    tk_val := v_rec.valid_t;
    v_cnt := vo_traced_atts_list.COUNT;
    v_cond := '(NVL(v_rec.'|| vo_traced_atts_list(1)||', ' || v_default || ') <> NVL(v_rec.' || vo_traced_atts_list(1)||'_FROM'
    ||' , ' || v_default || '))';
    cond := (BOOLEAN) v_cond;
    FOR v_i IN 2..v_cnt LOOP
    BEGIN
    v_cond := v_cond ||CHR(13)||CHR(10)||'OR (NVL(v_rec.'||vo_traced_atts_list(v_i)||', ' || v_default || ') <> NVL(v_rec.'||vo_traced_atts_list(v_i)||'_FROM'
    ||' , ' || v_default || '))';
    END;
    END LOOP;
    v_exec := 'SELECT ''x'' FROM DUAL WHERE '||v_cond;
    Add_Log('Event_Validating',v_user,v_event_validated,'INFO',v_exec);
    EXECUTE IMMEDIATE v_exec;
    /* Exception raised from here
    E-0008: Unkown Exception raised in Loop. ORACLE:ORA-00904: "V_REC"."ATT2_FROM": invalid identifier
    It seems that Oracle does not understand the dynamic reference v_rec.ATT2_FROM, v_rec.ATT2,... to test the condtion
    IF SQL%ROWCOUNT = 0     THEN -- condition is false ==> traced attributes does not changed
    -- update the REASON = 4 - not interested event
    v_exec := 'UPDATE CONTRACT_VALIDATED SET REASON = 4 WHERE CO_ID = '||pk_val||' AND VALID_T = '||tk_val;
    EXECUTE IMMEDIATE v_exec;
    END IF;
    FETCH v_rec_cv INTO v_rec;
    EXIT WHEN v_rec_cv%NOTFOUND;
    END LOOP;
    EXCEPTION
    WHEN OTHERS THEN
    Add_Log('SCD_VALIDATION',v_user,v_event_validated,'ERROR','E-0008: Unkown Exception raised in Loop. ORACLE:'||SQLERRM);
    RAISE ge_raise_error;
    END;
    END IF;
    CLOSE v_rec_cv;
    EXCEPTION
    WHEN OTHERS THEN
    Add_Log('SCD_VALIDATION',v_user,v_event_validated,'ERROR','E-0008: Unkown Exception raised in Loop. ORACLE:'||SQLERRM);
    RAISE ge_raise_error;
    END;

    Dear Andrew,
    Thank you so much for your suggestions, however, I think it will be better to let me explain more about the situation.
    I am working at Data Warehousing and Analysis part. The event tables are provided by other applications such as Customer OTLP system, Sales Management, etc. We therefore just have the results stored in the event tables (which could be wrong or inconsistency) and no way to force them to be valid by constraints. Before further processing the events , their records should be checked and overridden if possible, and that is the point I am trying to solve now.
    The Event table names, their attributes list, data types, primary key, timestamp columns etc are dynamic and are provided via parameters. I would like to write a procedure which can check the invalid events (not only update, but also insert, delete), protocol them, and override them if possible before processing further. Because the table name, attribute lists, data type, etc are not known in advanced, to my best knowledge, the only choice is generating dynamic PL/SQL code although it could suck the performance. The code you have seen in my first question is the output from the follwoing procedure, where the i_att_list provides the atts list has been parsed from other procedure invocation, i_pk is the primary key, i_tk is the time key, i_table_name is the table name (which is Event_Validation in previous example). The stucking point I have met now is that I do not know how to test the condition to detect the different between column pairs (ATT1 and ATT1_FROM, ...). Using Select from dual is just a dummy select for testing the where condition which must be formed as a string by that way.
    Thank you very much for your answer and looking forward to seeing your further recommendations or suggestions.
    Regards,
    Tho.
    CREATE OR REPLACE PROCEDURE Update_Validation
    ( i_att_list enum_string, -- list of attributes
    i_pk IN VARCHAR2, -- primary key column
    i_tk IN VARCHAR2, -- time key column
    i_table_name IN VARCHAR2 -- table_name - the columns format be checked
    ) AUTHID Current_User IS
    TYPE LoopCurType           IS REF CURSOR;
    ln_parallel NUMBER := 4;
    ge_raise_error EXCEPTION;
    v_user VARCHAR2(100);
    v_sql VARCHAR2(4000);
    v_string VARCHAR2(4000);
    v_crlf VARCHAR2(2) := CHR(13)||CHR(10);
    BEGIN
    SELECT sys_context('USERENV','current_schema') INTO v_user FROM DUAL;
    v_sql:= 'SELECT /*+ parallel(x,'||ln_parallel||') */ x.* FROM ' ||i_table_name|| ' x '||
              'WHERE CHANGE_KEY = ''U'''||
    ' order by '||i_tk;
    v_string := 'DECLARE v_rec '||i_table_name||'%ROWTYPE;' ||v_crlf||
              ' TYPE cv_type IS REF CURSOR; ' ||v_crlf||
    ' v_rec_cv CV_TYPE; ' ||v_crlf||
              ' v_cond VARCHAR2(4000); ' ||v_crlf||
         ' v_exec VARCHAR2(100);' ||v_crlf||
              ' v_default VARCHAR2(10):= ''~~''; ' ||v_crlf||
    ' tk_val '||i_table_name||'.'||i_tk||'.%TYPE;'||v_crlf||
    ' pk_val '||i_table_name||'.'||i_pk||'.%TYPE;'||v_crlf||
              ' v_cnt NUMBER;' ||v_crlf||
              'BEGIN ' ||v_crlf||
                        'OPEN v_rec_cv FOR ' ||v_sql ||';' ||v_crlf||
                        'FETCH v_rec_cv INTO v_rec;' ||v_crlf||
                             ' IF v_rec_cv%NOTFOUND THEN ' ||v_crlf||
                                  'Add_Log(''Event_Validating'',v_user,i_table_name,''INFO'',''I-0001: No-Procession needed'');'||v_crlf||
                             ' ELSE ' ||v_crlf||
                                  ' BEGIN '||v_crlf||
                                  ' LOOP '||v_crlf||
                                  'pk_val := v_rec.'||i_pk||';'||v_crlf||
    'tk_val := v_rec.'||i_tk||';'||v_crlf||
    'v_cnt := i_att_list.COUNT;' ||v_crlf||
                                            'v_cond := ''NVL(v_rec.''|| i_att_list(1)||'', '' || v_default || '') <> NVL(v_rec.'' || i_att_list(1)||''_FROM'''||v_crlf||
                             '||'' , '' || v_default || '')'';'||v_crlf||
                                            'FOR v_i IN 2..v_cnt LOOP'||v_crlf||
                                                 'BEGIN'||v_crlf||
                                                 'v_cond := v_cond ||CHR(13)||CHR(10)||''OR NVL(v_rec.''||i_att_list(v_i)||''), <> NVL(v_rec.''||i_att_list(v_i)||''_FROM'''||v_crlf||
                                                 '||'' , '' || v_default || '')'';'||v_crlf||
                                                 'END;'||v_crlf||
                                            'END LOOP;'||v_crlf||
                                            'v_exec := ''SELECT ''x'' FROM DUAL WHERE ''||v_cond;'||v_crlf||
                                            'EXECUTE IMMEDIATE v_exec;'||v_crlf||
                                            'IF SQL%ROWCOUNT = 0     THEN -- condition is false ==> traced attributes does not changed'||v_crlf||
                                            '-- update the REASON = 4 - not interested event'||v_crlf||
                                            'UPDATE '||i_table_name||' SET REASON = 4 WHERE '||i_pk||' = '||v_tk||' AND '||i_tk||' = '||tk_val||';'||v_crlf||
                                            'END IF;'||v_crlf||
                                       'FETCH v_rec_cv INTO v_rec;' ||v_crlf||
                                       'EXIT WHEN v_rec_cv%NOTFOUND;'||v_crlf||
                        ' END LOOP;'||v_crlf||
                                  'EXCEPTION' ||v_crlf||
                             'WHEN OTHERS THEN'||v_crlf||
                        'Add_Log(''SCD_VALIDATION'',v_user,i_table_name,''ERROR'',''E-0008: Unkown Exception raised in Loop. ORACLE:''||SQLERRM);'||v_crlf||
                        'RAISE ge_raise_error;'||v_crlf||
                                  'END;'||v_crlf||
                                  'END IF;'|| v_crlf||
                        'Close v_rec_cv;'||v_crlf||
                        'EXCEPTION' ||v_crlf||
                   'WHEN OTHERS THEN'||v_crlf||
              'Add_Log(''SCD_VALIDATION'',v_user,i_table_name,''ERROR'',''E-0008: Unkown Exception raised in Loop. ORACLE:''||SQLERRM);'||v_crlf||
              'RAISE ge_raise_error;'||v_crlf||
                   'END;';               
         Add_Log('SCD_UPDATE_VALIDATION',v_user,i_table_name,'INFO','I-0006: Update Validation : '||v_string);     
         EXECUTE IMMEDIATE v_string;
    EXCEPTION
    WHEN OTHERS THEN
    Add_Log('SCD_VALIDATION',v_user,i_table_name,'ERROR','E-0008: Unkown Exception raised in Loop. ORACLE:'||SQLERRM);
    END Update_Validation;

  • Query returning record even when not satisfying the where condition

    Hi,
    Below Query is returning value '1D' though it doesnt fall under the range '01' and '99'.
    I actually want to get the last 2 characters of the string and filter out if its not a number. Please help me.
    select * from (
    select substr('qwe1D',4) val from dual )
    where val between '01' and '99';
    Thanks
    Madhuri

    Sven W. wrote:
    Madhuri wrote:
    Hi,
    Below Query is returning value '1D' though it doesnt fall under the range '01' and '99'.
    I actually want to get the last 2 characters of the string and filter out if its not a number. Please help me.
    select * from (
    select substr('qwe1D',4) val from dual )
    where val between '01' and '99';
    Thanks
    MadhuriBut '1D' is between '01' and '99'. Simply because '1' is between '0' and '9'.
    One more example: '1111111' is also between '01' and '99'. This is how an string comparison works.
    To filter out strings that do not have numeric chars in them you can use several functions. regexp_substr/regexp_replace/translate/regexp_like etc.
    This might work:
    select * from (
    select substr('qwe1D',4) val from dual )
    where regexp_like(val,'\d{2}$');Edited by: Sven W. on Sep 27, 2012 12:35 PMThere is still one problem with this. It will return '00' which is not part of the original requirement. You have to add
    AND val != '00'

  • FA approver changes should not lead the cart to buyer

    Hi all,
    FA(Financial approver) changes the Product category, cart should not go back to buyers and if there is the change in Purchase types then  it should redetermine approvals based on new purchase types.
    In our current scenario, if FA approver changes the product category then it leads the cart to buyer for sourcing.so now the requirement is if FA approver changes the product category it should not leads to buyer.
    Please suggest your thoughts to proceed.
    thanks,
    sibi.

    Hi,
    Please check the BBP_WFL_SECURITY personalization key in personalization tab of PFCG or SU01 transaction.
    BBP_WFL_SECUR_BADI is also available.
    No authorization
    Changes to the document are not allowed while it is being approved.
    Low
    Changes can be made to the document. The approval workflow is restarted after every change.
    Medium
    Changes can be made to the document. After every change, the approval workflow either continues or is restarted.
    The system evaluates the start conditions and restarts the workflow if a new approval is required as a result of the change. If this is not the case, the approval workflow continues.
    High
    Changes can be made to the document. The current approval process always continues. A new approval workflow is not started when the document is changed.
    Regards,
    Masa

  • The list of extensions for InDesign now have a yellow triangle warning symbol in front of a good many of the extensions and when moused over i get one of two messages:  "Extensions may not function properly because it does not meet the dependency conditio

    The list of extensions for InDesign now have a yellow triangle warning symbol in front of a good many of the extensions and when moused over i get one of two messages:
    "Extensions may not function properly because it does not meet the dependency condition."
    OR
    Extension Status is not consistent with extension set configuration."
    The reason I opened the Extension Manager in the first place was to check to see if I had installed a third party extension.  And I was presented with these warning symbols.  I haven't added anything, I haven't done anything that would cause this.
    Does anyone know how to fix this???
    I am running OSX 10.9.5; Indesign CS6 version 8.0.2 And Adobe Extension Manager version  6.0.8.28.
    Thanks in advance!
    Nina

    Many InDesign pre-installed extensions (Those extensions you have immediately after InDesign installation) define dependency rules in their mxi files. Dependency means that one extension works well only if one or more other extensions are installed and enabled. If this condition is not met, the yellow triangle warning will be shown.
    You can select an extension with warning, click "Advanced" tag page in the lower right panel. You will see "This extension has dependency on: <extension name> ...". Check whether every extensions listed here are available and enabled. If not, enable them. Repeat these steps for all the extensions which have warning.

  • HOW TO EXTRACT THE PO CONDITIONS

    HI,
    i am using the following code,but in this i am not geting the po conditions values,is there any way to get the condition values into excel sheet.
    report ztest1.
    TABLES: EKKO.
    *PARAMETERS : P_EBELN TYPE EBELN.
    SELECT-OPTIONS: S_EBELN FOR EKKO-EBELN OBLIGATORY.
    TYPES: BEGIN OF T_PO,
             EBELN TYPE EBELN,
           END OF T_PO.
    DATA: IT_PO TYPE STANDARD TABLE OF T_PO,
          WA_PO TYPE T_PO.
    DATA : IT_ITEMS TYPE TABLE OF BAPIEKPO WITH HEADER LINE.
    DATA: PO_ITEMS_SHEDULE TYPE TABLE OF BAPIEKET WITH HEADER LINE.
    DATA: PO_ITEM_TEXT TYPE TABLE OF BAPIEKPOTX WITH HEADER LINE.
    DATA: PO_ITEM_ACCOUNT_ASSIGNMENT TYPE TABLE OF BAPIEKKN
    WITH HEADER LINE.
    DATA: PO_HEADER_TEXTS TYPE TABLE OF BAPIEKKOTX WITH HEADER LINE.
    DATA: PO_HEADER TYPE BAPIEKKOL.
    DATA: RETURN1 TYPE TABLE OF BAPIRETURN WITH HEADER LINE.
    DATA: RC TYPE I.
    SELECT EBELN INTO TABLE IT_PO FROM EKKO WHERE EBELN IN S_EBELN.
    PERFORM FILE_DELETE.
    LOOP AT IT_PO INTO WA_PO.
      CLEAR: PO_HEADER_TEXTS[], IT_ITEMS[], PO_ITEM_ACCOUNT_ASSIGNMENT[],
             PO_ITEMS_SHEDULE[], PO_ITEM_TEXT[], RETURN1[].
      CALL FUNCTION 'BAPI_PO_GETDETAIL'
        EXPORTING
          PURCHASEORDER              = WA_PO-EBELN
          ITEMS                      = 'X'
          ACCOUNT_ASSIGNMENT         = 'X'
          SCHEDULES                  = ' '
          HISTORY                    = 'X'
          ITEM_TEXTS                 = 'X'
          HEADER_TEXTS               = 'X'
        TABLES
          PO_HEADER_TEXTS            = PO_HEADER_TEXTS
          PO_ITEMS                   = IT_ITEMS
          PO_ITEM_ACCOUNT_ASSIGNMENT = PO_ITEM_ACCOUNT_ASSIGNMENT
          PO_ITEM_SCHEDULES          = PO_ITEMS_SHEDULE
          PO_ITEM_TEXTS              = PO_ITEM_TEXT
          RETURN                     = RETURN1.
      PERFORM DOWNLOAD_DATA: TABLES PO_HEADER_TEXTS USING 'BAPIEKKOTX',
                             TABLES IT_ITEMS USING 'BAPIEKPO',
                             TABLES PO_ITEM_ACCOUNT_ASSIGNMENT USING
    'BAPIEKKN',
                             TABLES PO_ITEMS_SHEDULE USING 'BAPIEKET',
                             TABLES PO_ITEM_TEXT USING 'BAPIEKPOTX'.
    ENDLOOP.
    *&      Form  DOWNLOAD_DATA
    FORM DOWNLOAD_DATA  TABLES   IT_TAB
                        USING    STRUC_NAME.
      DATA: IT_DD03P TYPE TABLE OF DD03P WITH HEADER LINE,
            IT_DD03P1 TYPE TABLE OF DD03P WITH HEADER LINE.
      DATA: IT_HEAD TYPE TABLE OF STRING,
            WA_HEAD TYPE STRING.
      DATA: L_TAB(1) TYPE C VALUE CL_ABAP_CHAR_UTILITIES=>HORIZONTAL_TAB.
      IF NOT IT_TAB[] IS INITIAL.
        CALL FUNCTION 'DD_GET_DD03P_ALL'
          EXPORTING
            TABNAME       = STRUC_NAME
          TABLES
            A_DD03P_TAB   = IT_DD03P
            N_DD03P_TAB   = IT_DD03P1
          EXCEPTIONS
            ILLEGAL_VALUE = 1
            OTHERS        = 2.
        IF SY-SUBRC EQ 0.
          LOOP AT IT_DD03P.
            IF SY-TABIX EQ 1.
              MOVE IT_DD03P-DDTEXT TO WA_HEAD.
            ELSE.
        CONCATENATE WA_HEAD IT_DD03P-DDTEXT INTO WA_HEAD SEPARATED BY L_TAB.
            ENDIF.
          ENDLOOP.
          APPEND WA_HEAD TO IT_HEAD.
        ENDIF.
      ENDIF.
      CALL FUNCTION 'GUI_DOWNLOAD'
        EXPORTING
          FILENAME                = 'C:\poextract.xls'
          APPEND                  = 'X'
          WRITE_FIELD_SEPARATOR   = 'X'
        TABLES
          DATA_TAB                = IT_HEAD
         FIELDNAMES              = IT_HEAD
        EXCEPTIONS
          FILE_WRITE_ERROR        = 1
          NO_BATCH                = 2
          GUI_REFUSE_FILETRANSFER = 3
          INVALID_TYPE            = 4
          NO_AUTHORITY            = 5
          UNKNOWN_ERROR           = 6
          HEADER_NOT_ALLOWED      = 7
          SEPARATOR_NOT_ALLOWED   = 8
          FILESIZE_NOT_ALLOWED    = 9
          HEADER_TOO_LONG         = 10
          DP_ERROR_CREATE         = 11
          DP_ERROR_SEND           = 12
          DP_ERROR_WRITE          = 13
          UNKNOWN_DP_ERROR        = 14
          ACCESS_DENIED           = 15
          DP_OUT_OF_MEMORY        = 16
          DISK_FULL               = 17
          DP_TIMEOUT              = 18
          FILE_NOT_FOUND          = 19
          DATAPROVIDER_EXCEPTION  = 20
          CONTROL_FLUSH_ERROR     = 21
          OTHERS                  = 22.
      IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
      CALL FUNCTION 'GUI_DOWNLOAD'
        EXPORTING
          FILENAME                = 'C:\poextract.xls'
          APPEND                  = 'X'
          WRITE_FIELD_SEPARATOR   = 'X'
        TABLES
          DATA_TAB                = IT_TAB
         FIELDNAMES              = IT_HEAD
        EXCEPTIONS
          FILE_WRITE_ERROR        = 1
          NO_BATCH                = 2
          GUI_REFUSE_FILETRANSFER = 3
          INVALID_TYPE            = 4
          NO_AUTHORITY            = 5
          UNKNOWN_ERROR           = 6
          HEADER_NOT_ALLOWED      = 7
          SEPARATOR_NOT_ALLOWED   = 8
          FILESIZE_NOT_ALLOWED    = 9
          HEADER_TOO_LONG         = 10
          DP_ERROR_CREATE         = 11
          DP_ERROR_SEND           = 12
          DP_ERROR_WRITE          = 13
          UNKNOWN_DP_ERROR        = 14
          ACCESS_DENIED           = 15
          DP_OUT_OF_MEMORY        = 16
          DISK_FULL               = 17
          DP_TIMEOUT              = 18
          FILE_NOT_FOUND          = 19
          DATAPROVIDER_EXCEPTION  = 20
          CONTROL_FLUSH_ERROR     = 21
          OTHERS                  = 22.
      IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    ENDFORM.                    " DOWNLOAD_DATA
    *&      Form  FILE_DELETE
    FORM FILE_DELETE .
      CALL METHOD CL_GUI_FRONTEND_SERVICES=>FILE_DELETE
        EXPORTING
          FILENAME             = 'C:\poextract.xls'
        CHANGING
          RC                   = RC
        EXCEPTIONS
          FILE_DELETE_FAILED   = 1
          CNTL_ERROR           = 2
          ERROR_NO_GUI         = 3
          FILE_NOT_FOUND       = 4
          ACCESS_DENIED        = 5
          UNKNOWN_ERROR        = 6
          NOT_SUPPORTED_BY_GUI = 7
          WRONG_PARAMETER      = 8
          OTHERS               = 9.
      IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
               WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    ENDFORM.                    " FILE_DELETE

    HI Ram
    Am not able to access SAP now, I guess FM: 'BAPI_PO_GETDETAIL' itself can return PO conditions as well. Please check the same.
    Kind Regards
    Eswar

  • CALL FUNCTION 'PRICING'  ,Not Feteching the PBOO and PBXX condititon record

    hi all,
    We are maintaintg the RFQ net price using the FM's MEX_SCHEMA_SUCHEN, ME_FILL_KOMK_PO,ME_FILL_KOMP_PO and PRICING
    in PRICING FM it is not reteriving the default Condition records(PB00,PBXX), am not able to see net price in ME48.
    Is there any thing needs to do in setting or configuration?
    Thanks

    HI,
    FORM USER_COMMAND USING r_ucomm like sy-ucomm
    ls_selfield TYPE slis_selfield.
    if ls_selfield-FIELDNAME =  'SD_DOC'.                        " Change
    SET PARAMETER ID 'AUN' FIELD ls_selfield-Value.           " Change
    CALL TRANSACTION 'VA02' AND SKIP FIRST SCREEN.
    clear IT_report-SD_DOC.
    endif.                                                   " Change
    endform.
    Edited by: Avinash Kodarapu on Jan 29, 2009 12:24 AM

  • Watching a film on my MB is great, until the air conditioning comes on...

    Low volume here. I have the volume maxed out in DVD player, system sound preferences and audio midi setup. It is still rather low. The other night I watched a film and the volume was much louder. Something has changed. Am I missing something anywhere? Thanks.

    No. Running on battery. Will the volume be louder plugged in? That would make sense I guess. I would test but can't use the MB at the moment. And it's not that the air conditioning causes the volume to lower. It's that the air conditioning makes it hard to hear because the speakers are so quiet. My AC isn't that loud though and that's why I bothered asking. I guess the problem sounded much more interesting than it is.

  • I just upgrade to lion on my iMac and also did the switch to iCloud and Paralle destop doest not what to open anymore .It says reactivate your mac and try again. What should I do now ? thanks for your help. Regards Eric

    I just upgrade to lion on my iMac and also did the switch to iCloud and Paralle destop doest not what to open anymore .It says reactivate your mac and try again.
    What should I do now ?
    thanks for your help.
    Regards
    Eric

    There's no need to go to the store if you don't want to. You can purchase and download the new version from the Parallels web site. In fact if you want to try it out, I believe you can do the download and get a two week trial version. Later you can purchase the serial number to make it official.
    I cannot be certain about your data, but I did not lose anything when I updated to Lion and faced a similar situation.
    Best of luck.

  • The flashlight in my iphone 4s keeps lighting even when it is switched off. I went through many articles and in those was mentioned presence of humidity could be one reason, but my phone was not prone to such conditions

    The flashlight in my iphone 4s keeps lighting even when it is switched off. I went through many articles and in those was mentioned presence of humidity could be one reason, but my phone was not prone to such conditions & it is the condition when i took it from its pouch. Kindly help

    If the phone is offline there is no way to track it or send a message to it.  You can place it in lost mode to lock it and send it a message (see http://help.apple.com/icloud/#/mmfc0f0165), but this will not take place until the phone goes back online, if it ever does.  If it does, you will get an email informing you.
    You might want to read this: http://support.apple.com/kb/HT5668.

  • My gen 4 ipod shuffle is not showing the green light when I switch it on (Green area shown). But when I plug it into the computer there initial orange blink and then solid orange. What wrong with it and how can I fix it.

    My gen 4 ipod shuffle is not showing the green light when I switch it on (Green area shown). But when I plug it into the computer there initial orange blink and then solid orange. What wrong with it and how can I fix it. 

    Hello Korawees,
    I was researching the issue you are describing and had a recommendation. The device is very simple, so the software troubleshooting for it is pretty limitted so I think you shoud restore the iPod shuffle and re sync the content. That way, if it is a software issue, this will fix it. Here is the article named Restoring iPod shuffle to factory settings found here: http://support.apple.com/kb/HT1481.
    Before Starting
    It is important to understand the difference between "update" and "restore." Update does not affect your settings or songs, it simply installs updated software that controls iPod shuffle. Restore erases the disk and restores iPod shuffle to its original factory condition with updated software. If you only need to update iPod shuffle, this should be done on the computer where music is normally synced. Updating on another computer will result in all songs being removed from iPod shuffle.
    Warning: Because Restore erases all songs and files on iPod shuffle, make sure to back up any files you've saved on iPod shuffle. Your songs, podcasts, and audiobooks can be synced back to your iPod shuffle if the items are part of your iTunes library.
    How to restore iPod shuffle
    Ensure that you have an active Internet connection as new versions of iTunes and iPod Software may need to be downloaded to your computer.
    Download and install the latest version of iTunes if you do not already have it installed.
    Open iTunes, and then connect iPod shuffle to your computer.
    After a few moments, iPod shuffle will appear in the Devices section on the left side of the Tunes window.
    Select iPod shuffle under Devices and you will see information about it appear in the main iTunes window under the Summary tab/button for iPod shuffle (3rd and 4th generation) or the Settings tab/button for iPod shuffle (1st or 2nd generation).
    The Version section tells you whether iPod shuffle is up to date or needs a newer version of the software.
    Click the Restore button. You will be presented with one or more restore options that may prompt iTunes to automatically download the latest iPod Software. The 4-possible restore options are:
    Restore Option 1: Restore - Restores with same iPod Software version already on iPod.
    Restore Option 2: Use Same Version - Restores with same iPod Software version already on iPod even though a newer version is available.
    Restore Option 3: Use Newest Version - Restores with the latest iPod Software currently on your computer.
    Restore Option 4: Restore and Update - Restores after downloading the latest iPod Software on your computer.
    If you are using a Mac, a message will appear prompting you to enter an administrator’s name and password.
    A progress indicator will appear on the computer screen indicating that the restore process has started. Do not disconnect iPod shuffle during the restore process.
    After the restore process is complete, the iPod shuffle's status light will flash orange continuously. The iPod Setup Assistant window will appear asking you to name your iPod and choose your syncing preferences as you did when you connected your iPod shuffle for the first time.
    When you come to step 7, I recommend Restore Option 4.
    Take care,
    Sterling

  • How do I just remove the current update to 3.6.12 and go back to an earlier version as I can not take the continual freeze ups ever few mins.? If this continues I will remove Firefox totally and switch to another browser I can not take this anymore.

    I can NOT take the continual freeze ups of my entire browser even worse when updating a page let alone just opening email. I closed the browser and have had to use even just microsoft or Google since this Firefox has gotten so horrible...
    I clear my history and my cache so many times a day I can not keep track anymore and that is insane to have to do it as many times as I am even worse that it does not help in the least!
    I have used Firefox for years now but if I have to remove it and switch to a different one by the days end I will and I will post in Facebook to all my friends who I had switch to Firefox what and why though some have already just switched to other browsers.

    First, that cannot be an iBook G4 as that machine cannot run Snow Leopard let alone Mountain Lion.  To run Snow Leopard it has to be an Intel processor, not a G4.  What does it show as the Model Identifier in About This Mac, More Info, System Report, Hardware, Model Identifier?
    Second, if you have erased the hard drive there should not be remnants of any prior content.  Even though Disk Warrior is saying nothing is wrong with the hard drive, it sounds as though there are problems.  You may want to consider simply replacing the hard drive so there are no questions about faults.  A good source is OWC, http://www.macsales.com where they also have on-line videos showing how to do the replacement.
    Third, you could also try again to restart using the Snow Leopard DVD/CD and use Disk Utility on that install disk to erase again, and do it a couple times, then try to install.  If it continues to refuse, then it sounds as though there is a fault with the hard drive.

  • How do I delete documents from my iPad that were added when it ran regular Acrobat, now that it has switched to DC?  The docs are not on the cloud, and DC does not seem to have a delete function for non-cloud docs.

    I use an iPad.  It automatically switched me from old-fashioned Acrobat to DC.  How do I delete docs that were put on my iPad with the old Acrobat?  They are not in the cloud, and DC does not seem to have a delete function for them.

    Hi,
    By default, Acrobat DC for iOS displays recently viewed files.  You need to switch to other file location (such as Local, Document Cloud, Creative Cloud) to delete, rename, move, or duplicate files.
    You can switch to Local, if you would like to see the files and folders that are locally stored on your iPad.
    Would you take a look at the following document to see how you can switch to other file location and delete files?
    How to manage files in Acrobat DC for iOS
    Please let us know if you have additional questions.  Thank you.

  • When I get a phone call or text message it will not make the sound. Just vibrate. But the switch is on normal. When I change it to vibrate the volume thing will not show. Nor will my up volume up key work. Is there any way to fix it?

    When I get a phone call or text message it will not make the sound. Just vibrate. But the switch is on normal. When I change it to vibrate the volume thing will not show. Nor will my up volume up key work. Is there any way to fix it?

    Basic troubleshooting from the User's Guide is reset, restart, restore (first from backup then as new).  Try each of these in order until the issue is resolved.

  • Firefox does not fully load Barclaycard Authentication site. It loads as far as asking for certain letters in my pasword but does not load the "Submit" button so I cannot continue with my purchase and have to switch to IE8 browser to purchase anything ov

    Firefox does not fully load Barclaycard Authentication site. It loads as far as asking for certain letters in my pasword but does not load the "Submit" button so I cannot continue with my purchase and have to switch to IE8 browser to purchase anything over the internet. Any clues?
    == This happened ==
    A few times a week
    == Couple of weeks ago

    Your UserAgent string in Firefox is totally messed up by another program that you installed, and Barclays doesn't know you are using Firefox 3.6.6 - it probably looks like IE 6.0 to that website.
    [http://en.wikipedia.org/wiki/User_Agent]
    type '''about:config''' in the URL bar and hit Enter
    ''If you see the warning, you can confirm that you want to access that page.''
    Filter = '''general.useragent.'''
    Right-click the preferences that are '''bold''', one line at a time, and select '''''Reset''''',
    Then restart Firefox

Maybe you are looking for

  • Open item clearing

    Hi! I post vendor invoice (transaction FB60) and outgoing payment (I use transaction F-02). When I closed open items (F-44) I saw that vendor turnover was multiplied. Clearing was created document with items (posting keys 27 and 37). How could I reso

  • How can I use the same catalog on PC and MAC?

    I keep my catalog and photos on an external hard drive.  I have both PCs and a MAC and I would like to be able to access the same catalog of photos on both my PC and my MAC using LR2.  I am using v 2.3.  The problem is the location of the photo is re

  • Atm0 clock rate on 1760 router

    I have a 2651xm router with wic1-adsl card and i've seen that by tweaking the atm0 and dialer0 settings I can literally double the download speed on my crappy adsl line. One of the settings I use on the 2651 is: # int atm0/0 # clock rate aal5 7000000

  • Authentication on device

    Hi everybody, Please help me. I'm using actionscrip 2 and FlashLite 2.x. I write an application which connect to server to login and use authentication. I use addRequestHeader function of XML object as the following:      var xml:XML = new XML();    

  • My Adobe products are not printing anymore,-

    -neither Illustrator nor Acrobat. Hallo guys, I'm using CS5 and my printer ist a Brother 2035. Since yesterday none of my adobe products print anymore. My system is the mac lion 10.7.2. Everything is up to date. I get no error message. It appears lik