The sales statistics are the most important SAP S/4HANA Utilities statistics for energy companies. For this reason we have gone to great lengths to improve performance during extraction, and the corresponding error handling. The following are the most important points:
Index Table DBESTA_BWPROT: All reconciliations that were created when invoicing contracts are saved here. During the extraction, the system checks whether the reconciliation key is closed, and then imports and extracts all documents for this reconciliation key.
Index Table DBESTA_BWPROTE: All invoicing documents that could not be extracted due to an incorrect status or error handling in the BEWSTA01 user exit are saved here. Correct the cause of the error.
During each extraction run the system attempts to reload documents from this index table. If this is not possible, then the entry remains in the table.
You must read the application log for the extraction. Either in BI monitor (a message is issued if an error has been detected in the extractor) or within the mass activity (transaction EBW_DQ_SS).
User Exit BWESTA01: If you need to make adjustments to the sales extractor (import additional tables, change values), then you should never use the RSAP0001 generic BI exit. Instead you should use this user exit. This exit is run for each billing document. As well as the billing document, it also has many other tables in the interface (note the interface for the exit). This avoids most performance-intensive and time-consuming saving procedures.
In addition, the exit also allows you to trigger an exception or error message of category 'E'. This means that the document is not extracted and written in the DBESTA_BWPROTE index table. Take advantage of the enhanced check in the exit. This has little effect on the performance, but significantly increases the time and effort required for subsequent corrections.
Some customers check address data here (for example, have the address codes been maintained?).
User Exit BWESTA02: Normally only those documents are extracted, whose reconciliation key have been closed. This restriction is not sufficient for some customers. In order to be able to make comparisons with the general ledger, you should only process the reconciliation keys that have actually been transferred to the general ledger.
For this reason you can check the reconciliation key in greater detail in this exit. However, you cannot extract an open reconciliation key.
For more information on the loading mechanism, see SAP note 438606.