Using an If-Else type condition in condition step

Hi Gurus,
I am requried to use an If - Else kind of condition before branching out.
I tried using the condition step and parantheses but am not able to figure out how to go about it.
IF you have used a simlar condition before,kindly share with me how I can achieve it.
My requirement is :
IF x = '123' or '456'.
do your work
elseif.
x = '111' or '222'.
do your work(2)
endif.
Thanks and Regards,
Ameya Kulkarni

Hi,
  There must be 4 element x1, x2, x3, x4
  At first select Multiple condition step.
Then in condition Tab select type as Switch.
Then click on the Condition of 1st line.
There a new window open. There click on expression select x1 , click on operator select = ,  click on expression 2 ,  write 123 ,  click on AND/OR, select OR , Then  click again on expression select x2 , click on operator select = ,  click on expression 2 ,  write 456 . 
Then click on the Condition of 2nd line.
There a new window open. There click on expression select x3 , click on operator select = ,  click on expression 2 ,  write 111 ,  click on AND/OR, select OR , Then  click again on expression select x4 , click on operator select = ,  click on expression 2 ,  write 222 .
In this way you can do this.

Similar Messages

  • Using two different calculation type  for one condition in purchasing

    hi
    purchasing price must be callculated as the mix of fixed and quantity calculation types, example is below;
    for material A whose purchasing unit of measure is quantity (piece) but base unit of measure is gr.
    1.from 1 gr to 500 gr discount must be 50 usd  as fixed,so 1 gr discount is the same with 499 gr discount.
    2. from 501 gr up to x, 0,10 usd per gr
    for example;
    if quantity = 10 and  total default gr from material 450, discount must be 50 usd as fixed.
    but during good receipt in migo 10 piece can be 600 gr so, price must be calculated as 600*0,10 = 60 usd.
    or vice versa,in purchasing order total gram can be gretaer than the gr which will be used in migo during good receipt .
    if quantity = 10 and  total default gr from material 600, discount must be 60 usd as scaled.
    but during good receipt in migo 10 piece can be 450 gr so, price must be calculated as 50usd as fixed.
    it s a little complicated.
    Thanks in advance.

    TW Typewriter
    If the coding is not written correctly, it would definitely affect the system performance.  This is not only for user exit but also will be applicable to routines.  So it makes no difference. 
    And is not difficult to get an access key to do this development
    Not in all cases.  In some projects, getting an Access Key itself is very difficult and it undergoes cumbersome process from client side.  So we have to take a decision on case to case basis whether to go with routine or user exit.
    G. Lakshmipathi

  • Table to be used to fetch conditon value of a condition type

    Hi Friends
                  I need to do some enhancements to a report where in I have to add a new column which adds up the netvalue of the invoice ( netwr) with the condition value of a tax condition ( octori ). To fetch the condition value of this conditon which is the appropriate table to be used ? Usually KONV is used but this is leading to slow performance. Is there any alternative table ? Can KONP be used ?
    Regards
    Mahesh

    Hi
    Pl find below tables related to pricing
    KOMK,KOMV,KOMP
    KONV Conditions for Transaction Data
    KONP Conditions for Items
    KOND Conditions (Data)
    KONH Conditions (Header)
    KONM Conditions
    T684 Condition Exclusion Groups
    T684G Condition Exclusion Groups: Condition Types
    T684S Condition Exclusion: Procedure Assignment
    T689 Download Profile for the Conditions
    T689K Reference: Download Profile - Pricing Procedures
    Axxx- condition record tabel
    eg: A304- is table for condition record for material with release status
    A305, a306,a074
    A000 Condition Table for Pricing
    I have not checked any of them. Dont know whether it will help you.
    regards

  • ME22N change Exchange rate type at price condition level

    Hello,
    In ME22N exchange rate type is 'M' by default. When a price condition has currency different than purchase order this 'M' rate is used.
    Now I need to change this 'M' rate but for particular price conditions (and exchange rate type can be different for each price condition). Don't ask me why:-) This requirement comes from business consultant and he knows that there is no user exit for this. I need to modify standard. The problem concerns items price conditions.
    I'm not asking you for a complete solution, but maybe you can give me a hint where to start? What is the function module which perform price calculation (where exchange rate is used) in ME22N.
    I tried to change KOMK-KURST in price condition rule (the procedure which is called to check if price condition has to be calculated or not). It is called for each price condition and I know a name of price condition. But I think the exchange rate type is read at the beginning and stays unchanged even I changed KURST.
    I also found function module READ_EXCHANGE_RATE, which has rate type 'M' by default. I could put my modification in place where it is called. But it is not called when I press button Update price. It is only called when I change the currency of condition and press enter. This FM is called in few places in ME22N but not when I'm refreshing prices. Maybe during a refresh it has already an exchange rate? If so, READ_EXCHANGE_RATE could be a solution, but... It is not called when price conditions are created for the very first time (when I create PO item). Maybe system calls different FM?
    I also tried to use trace (ST05) to see where systems reads from TCURR, but I think some buffers are used and TCURR is not in trace.
    So now I'm stuck hoping for your help.
    Best regards
    Rafal

    Prabhu Peram wrote:
    Hello Rafal ,
    >
    > still im trying to understand your requirements , anyhow if you change/propose new exchange rate at header level , then system wont put type as 'M'.
    >
    The problem is that if I set a new exchange rate type, it will be the same for all price conditions. My requirement is to have different exchange rate type for each price condition. The pricing procedure will loop at each price condition, and depending on condition name I need to have different exchange rate type.
    Example:
    condition XMER is in EUR and must be converted to USD (factor should be 1,234)
    condition XMET is in EUR and must be converted to USD (factor should be 1,567)
    Now the factor is the same for all price conditions.
    I have found interesting table XKOMV. It contains price conditions and there is a field with factor value. Now I will look for the place where this table is filled with data or for the place where I can modify factor values before XKOMV is used in pricing procedure.
    Best regards
    Rafal

  • Used of 362 & 363 Alternative formula for condition base value in Define Procedures (Tcode obyz)

    Dear
             what is the  used of 362 & 363 Alternative formula for condition base value in Define Procedures (Tcode obyz)

    362 is used for to pick base value to BASB condition type from MM pricing procedure
    363 is used for all sales tax {VAT (Inventory or set -off) & CST}.
    Tax Calculation on Freight - Different Scenarios
    Please  go through this  link  and  you will know  very well a bout  362 and  363  usage

  • Sale order showing a discount condition type twice in conditions Tab

    Dear Experts,
    Sale order showing a discount condition type twice in conditions Tab.
    Could you resolve my issue?
    Thanks in advance.
    Regards,
    Ravi

    Hi,
        In the Sales order, go to Conditions and in the Pricing 'Analysis' , check for where the system is determining the two values of this discount condition. It may be possible that it is determining from two condition tables.
    Also in the access sequence of this condition type, please make sure that the 'exclusive' indicator is checked for the condition tables.
    Please check if it helps.
    Thanks,
    Saurabh

  • How to select data from a table using a date field in the where condition?

    How to select data from a table using a date field in the where condition?
    For eg:
    data itab like equk occurs 0 with header line.
    select * from equk into table itab where werks = 'C001'
                                                      and bdatu = '31129999'.
    thanks.

    Hi Ramesh,
    Specify the date format as YYYYMMDD in where condition.
    Dates are internally stored in SAP as YYYYMMDD only.
    Change your date format in WHERE condition as follows.
    data itab like equk occurs 0 with header line.
    select * from equk into table itab where werks = 'C001'
    and bdatu = <b>'99991231'.</b>
    I doubt check your data base table EQUK on this date for the existince of data.
    Otherwise, just change the conidition on BDATU like below to see all entries prior to this date.
    data itab like equk occurs 0 with header line.
    select * from equk into table itab where werks = 'C001'
    and <b> bdatu <= '99991231'.</b>
    Thanks,
    Vinay
    Thanks,
    Vinay

  • Assigning Duty Types to Pricing Conditions

    Hello all,
    I have certain pricing conditions in the R/3 Purchase Order that I'd like to appear as a duty type in a Customs Declaration in GTS. I have assigned the GTS duty type to the R/3 Pricing Condition type in the IMG
    (SAP Customs Management -> Customs Processing -> Calculation of Customs Duty -> Assign Duty Types to Pricing Condition Types from Feeder Systems -> Assign Duty Type to Pricing Condition Type at Feeder System Level)
    and have activated the relevant BAdI in R/3, however the value I enter for the pricing condition in the PO doesn't get transferred. Does anyone have any experience with this that might be able to offer some advice as to why the value is not being transferred?
    Thanks in advance for your help.

    Hi ,
    You have to define
    Define Customs Duty Framework  under Calculation of Custom duty in GTS if you need different duty type  to be appeared on the custom shipment document..
    If you need further control on these Duty type then configure
    Configure Control Settings for Customs Duty Calculation
    And also Make sure that do the assigenment of pricing condition to your defined duty type in GTS under
    *Assign Duty Type to Pricing Condition Type at Feeder System
    Kind Regards,
    Sameer

  • Alternative calculation type and alternative condition base value

    In pricing procedure what is the difference between alternative calculation type and alternative condition base value?Kindly help

    Hi,
    Please check the forum before you post your questions as this question was answered a number of times earlier.
    Please check the below link which discusses in detail regarding the same.
    [Alt Cal Type and Cond Base Value|Alternative calculation type and alterantive condition base value in pricin;
    Regards,
    Phani Prasad

  • Copy value of condition type to another condition type *Not Percentage*

    Hi SAP community!
    How can I copy the value of a condition type to another condition type in my pricing procedure?  The rules are that these conditions are not Percentage. The calculation type is Quantity for the two conditions.
    I want to copy the value of condition type PMIN (Minimum Price) to another Z condition type.
    Thank you all

    Hi Lakshmipathi;
    In fact, there are two Z conditions that I need to have with the same value of the PMIN. I 've maintained my pricing procedure this way:
    For the PMIN, the step is 320
    For the ZPV1, the step is 920 and I put in "From " field 320 and in the "To" field 320
    For the ZPV0, the steo is 925 and I put in "From " field 320  and in the "To" field 320
    But when I looked the Conditions Tab in the sales order there is no value copied to the Z conditions. 
    In order to do this, my Z conditions do not need an access sequence assigned, right?

  • Difference between alternative calculation type and alternative condition b

    What is the difference between alternative calculation type and alternative condition base value?

    Hi Nitin
    Alternative calculation type:
    Suppose my gross price (PB) is Rs.100 for some metal per kg and I want to calculate surcharge based on todays RBI index of commodity rather than simply giving some 2%. I want to account todays RBI index in determinig Condition value.
    It is possible to do that by little alteration of regular routine.
    Alternate Condition base value:
    I am procuring 5 different variety of pens at different quantities at varying rates from 0 to 25 in a sing le PO. And I get the total header value of 1000. I will get a discount of 10% if the PO value reaches 1000. I have to subsequently pass on the discount of Rs.100 now to all the 5 line items. In general SAP calculates it based on the values of each line item and proportionately distributes. However If i want this discount to be distributed according to the quantity of each pen. You can acheive this with little alteration of Routine.
    Hope this clarifies your doubt.
    If found helpful, Pls reward.
    Regards
    edwin

  • What is the use of Alternative Calculation Type =2 and 4

    Dear Friends
    In pricing procedure in gross value, Net value for Item and Net value has Alternative calucation type is 2.
    What is the use of it?
    Without using it these value line are also fetching net value then what is the work of it. Please give me detail information with its effects in pricing condition tab page in sales document.
    Thanking You
    Arun

    Arun biswal,
    Correct Biswal. We have at varoius stages within Pricing procedure the "net value" which is calculated. Not only the alternative calculation type "2" is used if you notice carefully they are stored as subtotals at various levels.
    For Ex Gross Value  --> Subtotal =1 --> Calc type = 2
    similarly for Net value for Item --> Subtotal =2 --> Calc type = 2
    Net value 2 --> Subtotal =3 --> Calc type = 2
    See, these are used to calculate the net value at various levels in pricing. The calculation Type has got a set of routines that will facilitate us in pricing. SAP has provided certain clauclated formulas or routines to facilitate us during calculation within pricing . Here the "2" is used for calculation without tax and store it as subtotal and display it or use it for further calculations.
    We can use this "netvalue" amount for further calculations. It is used for clarity purpose when you issue a statement to customer. (like Confirmation order) at various levels like discount amt involved, Freight involved, Rebate amount invloved.....
    Even without this Calc type or using sub total u can proceed....
    Finally we have  TOTAL  --> Subtotal =A --> Calc type = 4
    In the above line we have Calc type as 4, which means when you use TAX this calc type is used .
    Routines are used to facilitate your process....
    Regards
    Sathya

  • Problem in using  Nested  IF-ELSE in Crystal Report  formula

    Hi Experts ,
                         I am having some problem using  Nested IF-ELSE in Crystal Report formula ,
    there is no error in the formula but only one condition is working. other condition is not working
    i am using this concept in formula workshop :-
    ' if{EXCISE_INVOICE;1.Basic Excise Duty BED@10 %}<>0 and{EXCISE_INVOICE;1.Education Cess @2%}<>0 and {EXCISE_INVOICE;1.Secondary Education Cess @1%}<>0 and {EXCISE_INVOICE;1.Central Sales Tax(CST)@2%}<>0
    then
    Sum ({EXCISE_INVOICE;1.Amount}) + {EXCISE_INVOICE;1.BedAmount@10%} + {EXCISE_INVOICE;1.EcessAmount@2%} + {EXCISE_INVOICE;1.SecCessAmount@1%} + {EXCISE_INVOICE;1.CSTAmount@2%}
    else
    if {EXCISE_INVOICE;1.Basic Excise Duty BED@10 %}<>0 and {EXCISE_INVOICE;1.Education Cess @2%}<>0 and  {EXCISE_INVOICE;1.Secondary Education Cess @1%}<>0 and   {EXCISE_INVOICE;1.Input VAT@5%}<>0  and {EXCISE_INVOICE;1.Addtional Tax@1%}<>0
    then
    Sum ({EXCISE_INVOICE;1.Amount}) + {EXCISE_INVOICE;1.BedAmount@10%} + {EXCISE_INVOICE;1.EcessAmount@2%}+{EXCISE_INVOICE;1.SecCessAmount@1% } + {EXCISE_INVOICE;1.VATAmount@5%} +{EXCISE_INVOICE;1.AddTaxAmount@1%(for VAT@4)}
    I want that  all conditions  should work and the condition which is applicable there according to formula it display the result,  if i add another condition then it should also work.
    kindly tell me the solution of this problem
    Regards
    Rahul

    Try this logic:
    if{EXCISE_INVOICE;1.Basic Excise Duty BED@10 %}!=0 and{EXCISE_INVOICE;1.Education Cess @2%} !=0 and {EXCISE_INVOICE;1.Secondary Education Cess @1%} !=0
    then
    Sum ({EXCISE_INVOICE;1.Amount}) + {EXCISE_INVOICE;1.BedAmount@10%} + {EXCISE_INVOICE;1.EcessAmount@2%} + {EXCISE_INVOICE;1.SecCessAmount@1%}
    else
    0
    +
    IF {EXCISE_INVOICE;1.Central Sales Tax(CST)@2%} !=0
    then
    {EXCISE_INVOICE;1.CSTAmount@2%}
    else
    IF  {EXCISE_INVOICE;1.Central Sales Tax(CST)@5%} !=0
    then
    {EXCISE_INVOICE;1.CSTAmount@5%}
    +
    if {EXCISE_INVOICE;1.Addtional Tax@1%} !=0
    then
    EXCISE_INVOICE;1.AddTaxAmount@1%(for VAT@4)}
    else
    0
    If not work, try SQL command.
    Thanks,
    Gordon

  • Duplicate Condition from Condition Exclusion procedure

    Hi Team- I have a condition Exclusion procedure with Type B- Best condition within the same condition type which is assigned to my PP, Condition Type Used is ZZZ1. Everything is working fine as expected in my sales order. Where as the ZZZ1 is showing twice in the order one with inactive and other with active indicator on. Due to some reasons we do not want show or list the inactive one in the sales order. How to do this?
    Reg
    Siva

    Hi Siva
    Try to use standard requirement 5 or 6 in condition ZZZ1 in pricing procedure definition.
    Regards,
    ZP

  • SharePoint caml query how to get if((condition && condition && (condition OR Condition)) items

    I uses U2U canl builder to get queries,
    How to write caml query for condition like,
    (UserName==ABC && date1>=GivenDate1 && (date2<=givendate2 || date2 == null) )
    one more
    (UserName==ABC && date1>=givenDate1 && (date2<=givenDate2 || date3 <= givenDate2) )
    SharePoint caml query if((condition && condition && (condition OR Condition))
    Thanks

    Hi,
    According to your post, my understanding is that you wanted to Caml query with nested AND and OR for multiple fields.
    The expression A AND B AND C looks like this:
    <And>
    A
    <And>
    B
    C
    </And>
    </And>
    Then the CAML query would look like as below.
    <Where>
    <And>
    <And>
    <Eq>
    <FieldRef Name='AssignedTo'/>
    <Value Type='User'>admin</Value>
    </Eq>
    <Geq>
    <FieldRef Name='StartDate' />
    <Value Type='DateTime'>2014-07-30T12:00:00Z</Value>
    </Geq>
    </And>
    <Or>
    <Leq>
    <FieldRef Name='DueDate' />
    <Value Type='DateTime'>2014-08-01T12:00:00Z</Value>
    </Leq>
    <IsNull>
    <FieldRef Name='DueDate' />
    </IsNull>
    </Or>
    </And>
    </Where>
    More reference:
    http://msdn.microsoft.com/en-us/library/ms196939.aspx
    http://sharepoint-experience.blogspot.com/2014/02/caml-query-with-nested-ands-and-ors-for.html
    http://aasai-sharepoint.blogspot.com/2013/02/caml-query-with-multiple-conditions.html
    Thanks & Regards,
    Jason Guo
    Jason Guo
    TechNet Community Support

Maybe you are looking for