ERPClimb logoERPClimb
AMDP
RAP / CDS / ODataadvanced 8 min read

AMDP Part 6: AMDP in Clean Core and ABAP Cloud

Preview · a free account unlocks the full lesson

Key takeaway

Use AMDP responsibly under clean core: what ABAP Cloud allows (C4-released objects, own objects), what to avoid on-premise, and how to design AMDP so it survives upgrades.

In this lessonShow sections

Visual overview

AMDP Part 6: AMDP in Clean Core and ABAP Cloud — learning sheetFlow: List USING objects of your AMDPs; classify: own / C4-released / other SAP → Replace "other SAP" with C4-released views or own data where possible → Ensure AMDPs are read-only; move writes to released APIs → Add authorization checks or a DCL-protected wrapper. Key ideas: WHAT ABAP CLOUD ALLOWS; WHY C4 IS A SEPARATE CONTRACT; ON-PREMISE STANDARD ABAP; NEVER WRITE SAP DATA WITH AMDP. Watch out: AMDP writing to SAP tables bypasses all business logic — not acceptable in clean-core designs.ERPClimb.com / RAP / LESSON 6/6 / LEARNING SHEETAMDP Part 6: AMDP in Clean Core and ABAP Cloud1 · HOW IT FLOWS1List USINGobjects of yourAMDPs; classify…2Replace"otherSAP" with…3Ensure AMDPs areread-only; movewrites to…4Addauthorizationchecks or a…2 · KEY IDEAS EXPLAINEDWhat ABAP Cloud AllowsAMDP is available in ABAP for Cloud Development(on HANA).The USING clause may reference:Why C4 Is A Separate ContractReading a CDS view in ABAP SQL (C1) lets the ABAPruntime apply client handling, access control andfuture changes. SQLScript reads the database…On-Premise Standard ABAPPrefer C4-released CDS views over SAP tables.Keep AMDP read-only.Never Write SAP Data With AMDPUpdating SAP tables in SQLScript bypassesvalidations, change documents, locks and follow-upprocessing. Change SAP data only via released APIs…3 · REMEMBER · WATCH OUTRememberClean core does not forbid AMDP — it restricts what AMDP may read.In ABAP Cloud, USING may contain only own objects and SAP objectsreleased for AMDP (contract C4).Never read SAP tables in new AMDP code; read released CDS views (C4)or your own data.!Watch outAMDP writing to SAP tables bypassesall business logic — not acceptablein clean-core designs.4 · IN A REAL PROJECTDuring an ABAP Cloud readiness assessment, 25 AMDP classes were found, 9 of which read SAP tables directly andone of which updated a status field in an SAP table "for performance". The update bypassed changedocuments, and auditors had flagged missing history. The team replaced the update with a released API call in…Original ERPClimb learning sheet • Verify against your SAP release and edition

Explanation

Clean core doesn't forbid AMDP outright — it restricts what AMDP may read. In ABAP Cloud, the USING clause may only contain your own objects and SAP objects released specifically for AMDP use, under release contract C4. New AMDP code should never read SAP tables directly; it should read released CDS views under C4, or your own data. And AMDP writing to SAP tables bypasses all of SAP's business logic, which isn't acceptable in a clean-core design.

Parts 1 through 5 covered AMDP technically; this final part places it in the clean-core world, with ABAP Cloud Part 7 covering release contracts in more depth.

ABAP Cloud allows AMDP as part of ABAP for Cloud Development, on HANA. Its USING clause may reference your own database tables, CDS entities and AMDPs, as well as SAP objects released under contract C4, "Use in ABAP-Managed Database Procedures and Functions." SAP tables and non-C4 views are rejected outright by the syntax check.

C4 exists as its own separate contract because reading a CDS view through ABAP SQL, under contract C1, lets the ABAP runtime apply client handling, access control and future changes on your behalf. SQLScript, by contrast, reads database objects directly, so SAP has to make an explicit separate promise that the database-level structure will stay stable — that promise is what C4 represents.

Free account

Create a free account to keep reading

You have read the opening of this lesson. A free ERPClimb account unlocks the rest of it, every other lesson and topic, and your learning history, so you can pick up exactly where you stopped. No card needed.

  • Full explanation
  • Code example
  • Real project scenario
  • Common mistakes
  • Best practices
  • Interview angle

One tap with Google works too. Every topic keeps its first lesson open to everyone.

Keep exploring

Check before use: lesson examples are educational, not a guarantee of correctness for your SAP edition or release. Sample code has not been executed on your SAP system. Confirm API availability, syntax, authorizations and business impact in an approved development or test environment.