on 2024 Jun 22 10:08 AM
ABAP Community,
can you tell me when to use Abap cds and when ABAP amdps?
pls illustrate with some real time examples / or Any business requirement which has been met with implementing AMDPs and not CDS .
ANIL
Request clarification before answering.
I would approach this differently, depending on the environment.
For on-premise development, CDS is useful for centralizing queries and handling simpler requirements. As things get more complex, AMDP (SqlScript) becomes preferable due to its more powerful features, such as window functions. In some cases, AMDP can even replace ABAP (code-pushdown).
I tend to use CDS for simple cases and AMDP for complex ones - or when I foresee that the requirement may become complex in the near future. If I start with CDS and things become surprisingly complex, it's possible to write AMDP and begin by calling the CDS anyway - so no harm done in many cases.
You can foresee business examples by inspecting what's possible by AMDP and not CDS; for example:
For managed ABAP RAP development, CDS would be your default starting point. However, if your requirement is too complex for CDS, you can leverage the power of AMDP via table functions or ABAP via virtual elements.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
go cds first
if you cannot get it done by cds, then amdp.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
| User | Count |
|---|---|
| 7 | |
| 6 | |
| 6 | |
| 4 | |
| 4 | |
| 4 | |
| 3 | |
| 3 | |
| 3 | |
| 3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.