Database and dictionary inconsistencies

During an S4HANA upgrade (for example with table PRCD_ELEMENTS) or during normal development work, you might end up in database and ABAP dictionary inconsistencies.

Questions that will be answered in this blog are:

  • How to detect database and ABAP dictionary inconsistencies?
  • How to repair database and ABAP dictionary inconsistencies?

Detection of database inconsistencies

In transaction DB02 you can get an overview of the missing database objects and inconsistencies:

Solving database and ABAP dictionary inconsistencies

The main procedure is explained in OSS note 1248769 – Inconsistency between database and ABAP Dictionary.

Start with transaction SE14 (database utility):

In the main screen click the Check button:

Result:

Pending on the check results, you need to Activate and Adjust the database.

Table reconstruction with DDIC user

Worst case you need to reconstruct the table. Be very sure this is needed before you execute it! Procedure for reconstruct: log on with user DDIC. Start transaction SE14. Select the menu option Table/Reconstruct (this option is only available for user DDIC).

Never use the database utilities in Shadow phase of an upgrade. In case of issues there: raise support message to SAP and only execute after instructions of SAP.