cancel
Showing results for 
Search instead for 
Did you mean: 

ECC 202 routine not supported in CRM - Need Solution

former_member193357
Participant
0 Kudos

Hello Expert,

I have a requirement where i need to replicate standard 202 routine form ECC to CRM. We raised an OSS message and SAP said 202 is not supported in CRM. But still we want to achieve this functionality.

so I am having few doubts regarding this since I am new to IPC java...

1) First can you confirm what is the flow when we create an sales order i mean CRM_COND_COM_BADI is called first or IPC java... i need to understand this basic first.

2) In IPC i cannot achieve the below part..

THIS PART DOES NOT SEEM TO BE POSSIBLE IN JAVA

komk-prsdt = rkomg-kdatu.


3) So how do i change update the pricing date, payment term through IPC since what i assume is that we cannot change the pricing structure in IPC.


4) CAN WE do something in BADI CRM_COND_COM_BADI??


Any help will be appreciated.


Regards,

Jan

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi Jan,

I'll try to answer first part of your questions. Badi CRM_COND_COM_BADI is called before IPC is processed. Badi can be used to fill communication structures that are passed on to IPC (changing parameter CS_ACS_I_COM).

Best regards

Marion

former_member193357
Participant
0 Kudos

Hi Marion,

Thanks for the clarification.

So you mean that we can change the ITEM communication structure either in this BADI or in IPC.

1) In IPC their are some restrictions which are not supported in CRM so in this case do the logic in BADI??? correct??

2) So for all the ECC custom pricing routines, if I do all the logic of this routines in BADI and not in IPC will there be any issues?? I know that that it should be done in IPC only but then why SAP had provided this BADI then??

Regards,

Jan,

Former Member
0 Kudos

Hi Jan,

sorry but I am not an expert for IPC and do not know the restrictions there. In the badi you can fill communication structures IPC needs to determine condition. For example you use field country in your condition table and in the badi you can fill it with your own logic.

Best regards

Marion

Former Member
0 Kudos

Hello Jan,

You will need to do most of your implementation in BAdI CRM_COND_COM_BADI. Only from there will you have access to the order API function modules to change things like the pricing date on the order.

In the BAdI you should then set a flag in the communication structure, and use that to switch the (Java) requirement on/off. Basically all your logic will be executed in ABAP in the BAdI, and at the end you simply pass the resulting flag to the pricing engine and use a very simple Java requirement to check the flag and return true/false.

Edit: Well, take the above as a general advice on how to implement something similar to this. I just had a look at requirement 202 and it looks like this can't be implemented in CRM the same way because of the different architecture. You will have to find a workaround I am afraid. 

Best regards,

Manuel

former_member193357
Participant
0 Kudos

Hello Manuel,

First of all thanks very much for the reply and looking 202 routine for this issue.

Now I got what the linkage between BADI and IPC. Thanks.

But I did not get what do you mean my different architecture for 202 routine? In BADI can't we right the logic of 202 and make it compatible with CRM.???

Regards,

Jan

Former Member
0 Kudos

As far as I understand requirement 202 a) changes data on the order, for example the pricing date and b) uses data from the pricing execution, like the xkomv structure.

In CRM, you can do a) in the COND_COM_BADI and you can do b) in a Java userexit. But you can't do both in the same place, which is why you need an entirely different design for requirement 202 in CRM. This would really be a non-trivial analysis and workaround and goes beyond what you can get from an SCN post I am afraid.

former_member193357
Participant
0 Kudos

Hello Manuel,

Thanks for the reply. One very last question...

I am following the below steps but still values are not SET in sales order. Can you please confirm if I am doing anything wrong in the IPC coding or in BADI.

1) SET price date, payment term in the BADI, for example...

     cs_acs_i_com-price_date = '20090501'.

     cs_acs_i_com-pmnttrms = 'V011'.

2) In IPC, below is the code I have written.

import com.sap.spe.base.logging.UserexitLogger;

import com.sap.spe.condmgnt.customizing.IAccess;

import com.sap.spe.condmgnt.customizing.IStep;

import com.sap.spe.condmgnt.finding.userexit.IConditionFindingManagerUserExit;

import com.sap.spe.condmgnt.finding.userexit.RequirementAdapter;

public class ZCUS_902 extends RequirementAdapter {

  /**

  * Purpose:

  */

  private static UserexitLogger userexitlogger = new UserexitLogger(ZCUS_902.class);

  private boolean checkPricingIndicator(IConditionFindingManagerUserExit item) {

  boolean isPricing = false;

  String priceIndicator = item.getAttributeValue("PRICING_INDICATOR");

  userexitlogger.writeLogDebug("PRICING_INDICATOR: "+priceIndicator);

  if (priceIndicator.equals("X") || priceIndicator.equals("B")) {

  isPricing = true;

  }

  userexitlogger.writeLogDebug("checkPricingIndicator: "+isPricing);

  return isPricing;

  }

  public boolean checkRequirement(IConditionFindingManagerUserExit item,

  IStep step, IAccess access) {

  boolean isCheckReq = false;

  isCheckReq = checkPricingIndicator(item);

  return isCheckReq;

  }

I have uploaded this code restart the VMC also then also after SAVE i check the order still PRICING DATE is not updated with 20090501.

Regards,

Jan

Former Member
0 Kudos

Hi Jan,

To change the pricing date you will have to use the order API, not the communication structure. And checking the pricing indicator will not do anything by itsself.

Again, unfortunately this is a rather complex topic (which is why 202 is not delivered in standard I suppose) and goes beyond what can be explained in a forum post.