SAP SD implementation notes-customer master data (two)

This article continues the content of the previous article, and continues to record the writing logic of the customer master data interface, related functional programs, and report development instructions.

Outgoing interface

If the peripheral system sends the customer master data information to us, the required fields are naturally determined by the needs of the recipient, that is, our SAP system. Similarly, when we need to send customer master data to the peripheral system, the required fields are determined by the peripheral system. When we talk about the interface fields with the person in charge of the peripheral system, we mainly focus on the needs of the other party. We need to feed back to SAP The logic here makes the two parties reach a consensus on the system understanding.

Just as we receive the customer master data sent by the peripheral system, there are mainly three actions: create, modify, and delete. When we send customer information to the peripheral system, these three actions trigger the interface to send the information.

If the peripheral system does not require high timeliness, that is, SAP does not need to send to the peripheral system immediately after creating a customer, but can send it regularly, then we can develop a program to capture the customers created and modified within a certain period of time, and The main data is sent out through the interface.

Grab the newly created customer
and search for all data whose creation date meets the field date of the selection screen in the KNB1 table, and query the log table with the customer number and company code as the KEY value. If the information type is S, the record has been successfully sent, then Skip this record. For records that have not been sent, other fields are obtained according to the access logic and written to the log table.

Crawl the modified customers
in the table CDHDR through OBJECTCLAS= DEBI and meet the conditions of the screen date to obtain the customer number of the OBJECTID field, remove the duplicate values, put the customer number into the KNB1 table, and filter out the customer numbers and Company code, the customer number and company code are KEY values, and other fields are obtained according to the access logic and then written into the log table.

Through the above two methods, the customer number and company code that need to be sent are captured (to distinguish between creation and modification). Then according to certain logic, grab the interface field in the table KNA1\KNVV\KNB1 etc., and then send it out through the interface.

Customer master data related functions

From the perspective of user-friendly operation and efficiency improvement, we usually develop simple and easy-to-use programs for the creation and modification of customer master data. Here is a brief introduction to what functions are usually needed. The specific logic is not repeated. We have done SD Everyone should understand.
The client master data batch guide program refers to the batch creation of clients by uploading excel. The fields, format, and sequence suggestions in the excel template are consistent with other interface fields in the project that involve customer master data. The batch creation of customer master data belongs to the program that basically every implementation project will have. It is estimated that there are ready-made codes in the hands of ABAPer, which can be used after modification.
Expand customer sales view and company view. In addition to creating customers in batches, it is usually necessary to consider the function of expanding customer master data in batches. For example, a customer exists in both company 1000 and company 2000 and uses the same customer code. Now, the customer has created master data in SAP and belongs to company 1000. Then, we need to consider expanding the sales view and company view of company 2000 for the customer. It is recommended that the batch guidance program be separated from the batch expansion sales view, the program the company tried.
In addition, consider the function of modifying customer master data in batches. This function can refer to the logic of modifying customer master data in the standard batch modification program (T CODE:MASS).

Customer master data report

The report is relatively simple. According to the business needs, it lists which fields are needed. If you can get the data directly from the table, you can get the data directly. If you can't write the logic for ABAPer to develop. In addition, it is usually recommended that the customer master data table take KNA1 as the base table, and left-connect with other tables, such as KNVV\KNB1.

Guess you like

Origin blog.51cto.com/9027965/2544652