cancel
Showing results for 
Search instead for 
Did you mean: 

Interaction record created without 'anchor'

Former Member
0 Kudos

Hi all

while creating an interaction record using the following code, where Z001 is a transaction code for IR

    lo_bol_core = cl_crm_bol_core=>get_instance( ).

    lo_bol_core->start_up( 'BT' ).

   ls_params-name   = 'PROCESS_TYPE'.

   ls_params-value  = 'Z001'.

   append ls_params to lt_params.

    call method lo_bol_core->root_create

      exporting

        iv_object_name  = 'BTOrder'

        iv_create_param = lt_params

        iv_number       = 1

      receiving

        rv_result       = lo_btorder_col.

*

    lo_btorder = lo_btorder_col->get_current( ).

I get an IR created without 'anchor', it means without the following relation created which it is supposed to be done automatically by the system

BTORDER -> BTADMINH -> BTHeaderDocFlowSet -> BTDocFlowAll -> BTDocFlow

and the following property created

OBJTYPE_B = CRMCICANCH

Any advise?

Regards

MG

Accepted Solutions (0)

Answers (1)

Answers (1)

former_member193634
Active Participant
0 Kudos

Hi,

You may want to have a look at method GET_INTERACTION_RECORD of class CL_ICCMP_CUCOIREC_IMPL.

This is where the interaction record gets created on confirming the identification of a BP.

You will notice this part :

* set anchor objects into document flow of interaction record
*  - indentifies business transaction as interaction record
*    (has to be called before set_interaction)
     me->set_anchor( ir_btorder = lr_irec ).

The anchor is set here. You may want to reproduce that into your development.


Hope this helps.


Best regards.


Sylvain

Former Member
0 Kudos

Hi Sylvain

thanks for answering.

That's fine. It's called during BP confirmation though. I am actually expecting to have similar behavior while interaction record creation therefore automatically by the system. Is it only my assumption?

Regards

MG

former_member193634
Active Participant
0 Kudos

Hi,

Could you elaborate more on your requirement ?

Is it a custom development ? If so, where is it located ?

Calling the ROOT_CREATE method will not set up automatically the anchor to the interaction record.

The standard behaviour can be found in the method I gave you. You will notice that it does create the IR objtect (via method ROOT_CREATE, like you did in your code), and then does some other stuff like setting the anchor.

Sylvain

Former Member
0 Kudos

Hi

Actually since the anchor is the way to differentiate an IR I thought and I actually read somewhere that it should be created by standard. Thus I was thinking about a bug for Bol Api ROOT_CREATE.

Regards

MG

former_member193634
Active Participant
0 Kudos

Hello again,

Does not seem like a bug. The fact that a Business Transaction is an IR is taken into account in the IC scenario, in the method I gave you. The ROOT_CREATE method does not directly take care of that distinction.

Did you manage to make work your requirement with the information I gave you ?

Best regards,

Sylvain

Former Member
0 Kudos

Hi

yes it was a work around that I had already done similar to the one you showed me. I does work if I implement it. Thanks for pointing it out.

Regards

MG