cancel
Showing results for 
Search instead for 
Did you mean: 

Accidental Double BP Generation

thibaud_loyriac
Explorer
0 Kudos

Dear Community,

We are using MDG with Vendor UI in NWBC.

When we create a Vendor (new Business Partner) sometimes a second BP is generated randomly when we click on "Save" in the change request. This second BP is empty and has a temporary ID ('$7890' for example).

This is very painful for end users as they need to withdraw (if it's a draft) or even delete the change request when this second and unwished BP has been generated along with the correct one.

If someone has already had this case, it would help us a lot, we have many issues in resolving this problem, mainly because it is not happening at each change request. (it is finally not occuring that often related to the high activity our system has but...)

Thanks a lot for having read this message and thanks in advance for your help ! 🙂

Regards,

Thibaud.

Accepted Solutions (0)

Answers (5)

Answers (5)

former_member190949
Active Participant

Hello Thibaud,

I have 2 queries-

1. The unwanted BP that is generated , is it assigned a number after Final Activiation of the CR too? You mentioned that it has a temporary number. But that would be while the CR is in the approval process. Is a BP with a number generated after final activation?

2. If yes to point 1- is this unwanted BP of category Organisation (i.e. is it a Vendor) or is it of Category Person?

If it is of category Organisation then there is no issue with Contact Person scenario & we may be able to narrow down the exact scenario when this issue occurs.

Thanks

kavi

thibaud_loyriac
Explorer
0 Kudos

Hi Kavita,

--> The unwanted BP that is generated is never assigned to a number because during the next activation of the CHR, we face an 'Process Errors after Activation', with a Log saying that "BP Category does not exist" for the BP GUID that we did not want to get :

Thanks a lot,
Thibaud.

former_member190949
Active Participant
0 Kudos

Hello Thibaud,

If the Log mentions that "BP Category does not exist" then i think you should raise it to SAP in this case.

Thanks,

Kavita

thibaud_loyriac
Explorer
0 Kudos

Hello Community,

I have tried the scenario Kavita proposed me and in our system the issue seems to not be the same.

Unfortunately, we still don't know when exactly this happens...

If someone has also be facing a similar issue do not hesitate ! 🙂

Thanks in any case,
Thibaud.

Former Member
0 Kudos

Hi Thibaud,

For MDG, any person is a BP: customer, vendor, consumer, contact person, etc

In my Project, I defined a different number range for contact person, then when the user creates a BP with contact person, these contact persons are created with another number range.

First, I configured two Number Ranges

SPRO: Cross-Application Components > SAP Business Partner > Business Partner > Basic Settings > Number Ranges and Groupings > Define Number Ranges

Number Range / From / To

01 0000000001 9999999999

Z1 0900000000 0999999999

After, I defined two BP Groups, assigning their number ranges:

SPRO: Cross-Application Components > SAP Business Partner > Business Partner > Basic Settings > Number Ranges and Groupings > Define Groupings and Assign Number Ranges

Group / Number Range

0001 01

ZCONS Z1

In BADI implementation for BP_HEADER entity, I change the value of BU_GROUP. This method will be called for each BP. For example, if you have a BP with 2 contact person, this method will run 3 times, one for BP and two for contact person.

MDGIMG: General Settings > Data Quality and Search > Business Add-Ins > BAdI: Define Validations/Derivations

METHOD if_ex_usmd_rule_service~derive_entity.
   DATA: lo_mdg_data TYPE REF TO yclbp_data_rules.
    DATA: it_data_entity_bprel TYPE usmd_ts_data_entity.
    DATA: lv_partner1 TYPE bu_partner.
    DATA: lv_cr_bus_act   TYPE usmd_process.


    FIELD-SYMBOLS:
      <lt_data>           TYPE INDEX  TABLE,
      <ls_bp_header>      TYPE        any,
      <lv_partner>        TYPE        bu_partner,
      <lv_group>          TYPE        bu_group.


    CASE id_entitytype.
      WHEN 'BP_HEADER'.

        "--- get relationship data 
        CREATE OBJECT lo_mdg_data
          EXPORTING
            io_model = io_model.

        lo_mdg_data->get_partner1_from_rel( IMPORTING partner1 = lv_partner1 ).
        "---

        lv_cr_bus_act = lo_mdg_data->cr_bus_act.

        "--- Assign value to BU_GROUP  
        ASSIGN ct_data TO <lt_data>.
        CHECK <lt_data> IS ASSIGNED. 
        READ TABLE <lt_data> INDEX 1 ASSIGNING <ls_bp_header>.  
        CHECK <ls_bp_header> IS ASSIGNED.  
        
        ASSIGN COMPONENT 'BP_HEADER' OF STRUCTURE <ls_bp_header> TO <lv_partner>.
        ASSIGN COMPONENT 'BU_GROUP' OF STRUCTURE <ls_bp_header> TO <lv_group>.

        IF ( lv_partner1 IS INITIAL OR lv_partner1 EQ <lv_partner> ).
          
          IF ( <lv_group> IS INITIAL AND lv_cr_bus_act NE 'BPP2' ).
            <lv_group> = 'ZCONS'.  “ CONSUMER
          ELSE.
            <lv_group> = '0001'. “ CONTACT PERSON 
          ENDIF.
        ELSE.
          <lv_group> = '0001'. “ CONTACT PERSON
        ENDIF.
        "---

    ENDCASE.
  ENDMETHOD.

thibaud_loyriac
Explorer
0 Kudos

Thanks a lot for your help Evandro Klen Stephen de Azeredo !

My point is that in our case, the BP that is generated 'accidentally' has no BP_GROUP. That's why I'm not sure our issue is related to the BP Group assignment.

In which context did you put this method in place ? Was it because you faced exactly the same issue as us, without BP Group ?

Thanks again,

Thibaud.

thibaud_loyriac
Explorer
0 Kudos

Hello Community,

I have tried the scenario Kavita proposed me and in our system the issue seems to not be the same.

Unfortunately, we still don't know when exactly this happens...

If someone has also be facing a similar issue do not hesitate ! 🙂

Thanks in any case,
Thibaud.

thibaud_loyriac
Explorer
0 Kudos

Hello,

Yes we use contact persons functionality ! How did you manage this ?

Regards,

Thibaud.

former_member190949
Active Participant
0 Kudos

Hello Thibaud,

I can only tell you the exact scenario when this occurred & unfortunately not teh solution. We have raised it with SAP- but unfortunately SAP is unable to connect to our system due to some network issues 😞

Scenario-This issue occurred when someone added a Contact Person & Saved the CR & thereafter the Contact Person is deleted.This deletion of Contact Person should happen before Final Activation.What would happen is that this extra unwanted BP that is created (is of Category 1 = Person ). This BP of Person category however has NO RELATIONSHIP with the Vendor BP(of Category =2, Organization)

The system thus Create an unwanted BP of PERSON type which is not intended to be in the system and was deleted in the CR. This BP exists in table BUT000 but not in table BUT050.

Please compare the scenario. In case it is the same , I will let you know the solution if & when SAP replies.

In case you get a reply from SAP before we do please update us.

Sorry to not be of much help

thanks,

Kavita

former_member190949
Active Participant
0 Kudos

To put simply-

When contact person is added and then deleted without saving results then

  • contact person is successfully delete in MDG CR UI
  • No Unwanted BP-Contact Person is created


Issue occurs when contact person is added, changes are saved, then contact person is deleted,then

  • contact person is successfully deleted in MDG CR UI
  • BUT Unwanted BP- Contact Person is created and does not get deleted.

Thanks.

thibaud_loyriac
Explorer
0 Kudos

Hello Kavita,

I have tried the scenario you proposed and in our system the issue seems to not be the same. Unfortunately, we still don't know when it happens... However I'm still interested in the following of your issue solving as the same correction by SAP might correct our issue also...

Thanks in any case,
Thibaud.

former_member190949
Active Participant
0 Kudos

Hello Thibaud,

Are you using the Contact Person functionality?

I faced a similar issue using the Vendor like UI, but this was with respect to the Contact Person related BP.

Thanks,

Kavita