ABAP Cloud vs Classic ABAP: The Complete Comparison 2025

Category
Comparison
Published
Author
Johannes

ABAP Cloud vs. Classic ABAP - what are the differences? Which version should you learn? This complete comparison shows you side-by-side what has changed and why.

Overview: ABAP Cloud vs Classic ABAP

AspectClassic ABAPABAP Cloud
Since when?1980s2019 (ABAP Environment)
Available inSAP ECC, S/4HANA On-PremSAP BTP, S/4HANA Cloud
Development modeAll ABAP featuresReleased APIs only
UI technologyDynpro, WebDynpro, FioriFiori only
DeploymentOn-PremiseCloud & On-Premise
Upgrade stabilityOften manual adjustmentsAutomatic (Clean Core)
Learning curveMediumSteep (many new concepts)

In short: ABAP Cloud is the modern, cloud-ready variant of ABAP with stricter rules but better maintainability.


1. Syntax Comparison: Old vs. New

1.1 Data Declaration

Classic ABAP:

DATA lv_name TYPE string.
DATA lv_count TYPE i.
lv_name = 'Max Mustermann'.
lv_count = 42.
DATA lt_customers TYPE TABLE OF ty_customer.
DATA ls_customer TYPE ty_customer.

ABAP Cloud:

" Inline declaration preferred
DATA(lv_name) = 'Max Mustermann'.
DATA(lv_count) = 42.
DATA(lt_customers) = VALUE ty_customer_table(
( id = 1 name = 'Max' )
( id = 2 name = 'Anna' )
).

Difference: ABAP Cloud prefers inline declarations for shorter code.


1.2 String Operations

Classic ABAP:

DATA lv_full_name TYPE string.
CONCATENATE lv_first_name lv_last_name
INTO lv_full_name
SEPARATED BY space.
" Or
CONCATENATE 'Hello ' lv_name '!' INTO lv_greeting.

ABAP Cloud:

" String Templates
DATA(lv_full_name) = |{ lv_first_name } { lv_last_name }|.
DATA(lv_greeting) = |Hello { lv_name }!|.
" With formatting
DATA(lv_price) = |Price: { lv_amount CURRENCY = lv_currency }|.

Difference: CONCATENATE is obsolete in ABAP Cloud. String templates are more modern and powerful.


1.3 Internal Tables

Classic ABAP:

DATA ls_customer TYPE ty_customer.
READ TABLE lt_customers INTO ls_customer
WITH KEY id = lv_id.
IF sy-subrc = 0.
" Customer found
WRITE: ls_customer-name.
ENDIF.
" Modify row
ls_customer-name = 'New Name'.
MODIFY TABLE lt_customers FROM ls_customer.

ABAP Cloud:

" Table Expression
TRY.
DATA(ls_customer) = lt_customers[ id = lv_id ].
" Customer found
cl_demo_output=>display( ls_customer-name ).
" Modify row directly
lt_customers[ id = lv_id ]-name = 'New Name'.
CATCH cx_sy_itab_line_not_found.
" Not found
ENDTRY.
" Or: With OPTIONAL (no exception)
DATA(ls_customer) = VALUE #( lt_customers[ id = lv_id ] OPTIONAL ).

Difference: Table expressions are shorter and more modern, but require exception handling.


1.4 Control Structures

Classic ABAP:

IF lv_status = 'A'.
lv_message = 'Active'.
ELSEIF lv_status = 'I'.
lv_message = 'Inactive'.
ELSE.
lv_message = 'Unknown'.
ENDIF.
CASE lv_type.
WHEN 'A'.
lv_result = 'Type A'.
WHEN 'B'.
lv_result = 'Type B'.
WHEN OTHERS.
lv_result = 'Other type'.
ENDCASE.

ABAP Cloud:

" COND Expression (Inline IF)
DATA(lv_message) = COND string(
WHEN lv_status = 'A' THEN 'Active'
WHEN lv_status = 'I' THEN 'Inactive'
ELSE 'Unknown'
).
" SWITCH Expression (Inline CASE)
DATA(lv_result) = SWITCH string( lv_type
WHEN 'A' THEN 'Type A'
WHEN 'B' THEN 'Type B'
ELSE 'Other type'
).

Difference: COND/SWITCH are functional (return values) instead of imperative.


1.5 Loops & Iterations

Classic ABAP:

DATA lv_total TYPE i VALUE 0.
LOOP AT lt_orders INTO DATA(ls_order).
lv_total = lv_total + ls_order-amount.
ENDLOOP.
" Extract names
DATA lt_names TYPE TABLE OF string.
DATA ls_name TYPE string.
LOOP AT lt_customers INTO DATA(ls_customer).
ls_name = ls_customer-name.
APPEND ls_name TO lt_names.
ENDLOOP.

ABAP Cloud:

" REDUCE (for aggregations)
DATA(lv_total) = REDUCE i( INIT sum = 0
FOR ls_order IN lt_orders
NEXT sum = sum + ls_order-amount ).
" FOR Expression (for transformations)
DATA(lt_names) = VALUE string_table(
FOR ls_customer IN lt_customers
( ls_customer-name )
).
" With filter
DATA(lt_active_names) = VALUE string_table(
FOR ls_cust IN lt_customers
WHERE ( status = 'ACTIVE' )
( ls_cust-name )
).

Difference: REDUCE/FOR are declarative and often more performant.


1.6 Database Access

Classic ABAP:

" SELECT * not recommended, but allowed
SELECT * FROM mara
INTO TABLE @DATA(lt_materials)
WHERE mtart = 'FERT'.
" Without @-escaping (old syntax)
SELECT matnr maktx FROM mara
INTO TABLE lt_materials
WHERE mtart = 'FERT'.

ABAP Cloud:

" SELECT * FORBIDDEN in ABAP Cloud
" Only Released CDS Views + Explicit fields
SELECT Product, ProductDescription
FROM I_Product
INTO TABLE @DATA(lt_products)
WHERE ProductType = 'FERT'.
" @-escaping is MANDATORY

Difference:

  • SELECT * forbidden
  • Only Released APIs (CDS Views with Released status)
  • @-escaping mandatory

1.7 Subroutines (FORM/PERFORM)

Classic ABAP:

" Allowed in Classic
FORM calculate_total USING pv_amount TYPE p
CHANGING pv_total TYPE p.
pv_total = pv_amount * '1.19'.
ENDFORM.
PERFORM calculate_total USING lv_amount
CHANGING lv_total.

ABAP Cloud:

" FORM/PERFORM FORBIDDEN
" Only classes & methods
CLASS lcl_calculator DEFINITION.
PUBLIC SECTION.
CLASS-METHODS calculate_total
IMPORTING iv_amount TYPE p
RETURNING VALUE(rv_total) TYPE p.
ENDCLASS.
CLASS lcl_calculator IMPLEMENTATION.
METHOD calculate_total.
rv_total = iv_amount * '1.19'.
ENDMETHOD.
ENDCLASS.
DATA(lv_total) = lcl_calculator=>calculate_total( lv_amount ).

Difference: ABAP Cloud enforces object-oriented programming.


2. UI Development

Classic ABAP

Available Technologies:

  • Dynpro (classic SAP GUI)
  • WebDynpro ABAP
  • SAP Fiori (with SAPUI5)
  • BSP (Business Server Pages)

Dynpro Example:

" Screen 100 with MODULE
CALL SCREEN 100.
MODULE status_0100 OUTPUT.
SET PF-STATUS 'MAIN'.
SET TITLEBAR 'TITLE'.
ENDMODULE.
MODULE user_command_0100 INPUT.
CASE sy-ucomm.
WHEN 'SAVE'.
" Save
WHEN 'BACK'.
LEAVE TO SCREEN 0.
ENDCASE.
ENDMODULE.

ABAP Cloud

Available Technologies:

  • SAP Fiori (with SAPUI5 or Fiori Elements)
  • Dynpro FORBIDDEN
  • WebDynpro ABAP FORBIDDEN

Fiori Elements (RAP) Example:

" No UI code needed! Automatically generated from annotations
" Service Binding
@EndUserText.label: 'Book Service'
define service ZUI_BOOK_O4 {
expose ZC_Book as Book;
}
" Metadata Extension (UI layout)
@UI.lineItem: [{ position: 10 }]
@UI.identification: [{ position: 10 }]
BookId;

Difference: Dynpro is history. Fiori is the future (web-based, responsive).


3. Database Access & APIs

Classic ABAP

Access to:

  • All SAP tables (MARA, VBAK, KNA1, etc.)
  • All function modules
  • All BAPIs
  • All classes (including internal)

Example:

SELECT matnr maktx FROM mara
INTO TABLE @DATA(lt_materials)
WHERE mtart = 'FERT'.
CALL FUNCTION 'BAPI_MATERIAL_GET_DETAIL'
EXPORTING
material = lv_matnr
IMPORTING
material_general_data = ls_material.

ABAP Cloud

Access to:

  • Only Released APIs (CDS Views, classes with Released status)
  • No direct table access to SAP tables
  • Many old BAPIs not available

Example:

" Released CDS View
SELECT Product, ProductDescription
FROM I_Product
INTO TABLE @DATA(lt_products).
" RAP/EML instead of BAPI
READ ENTITIES OF I_Product
ENTITY Product
ALL FIELDS
WITH VALUE #( ( Product = lv_product_id ) )
RESULT DATA(lt_result).

How to find Released APIs:

  1. ADT: Ctrl+Shift+A → Search with filter “API State: Released”
  2. SAP API Business Hub: api.sap.com
  3. Released Objects: Green checkmark in ADT

Difference: ABAP Cloud has access restrictions for better upgrade stability.


4. RAP (RESTful ABAP Programming)

Classic ABAP

RAP available?

  • Yes, but optional (from S/4HANA 2020)
  • You can still use BAPIs, Dynpro, etc.

ABAP Cloud

RAP available?

  • Main development model
  • For transactional apps, RAP is the only way

RAP Components:

ComponentPurpose
CDS ViewData model
Behavior Definition (BDEF)CRUD logic, actions, validations
Behavior Implementation (BIL)Business logic in ABAP
Service DefinitionWhich entities are exposed?
Service BindingOData Service (V2 or V4)

Example - Managed Scenario:

managed implementation in class zbp_i_book unique;
strict ( 2 );
define behavior for ZI_BOOK alias Book
persistent table zbook_tab
{
create;
update;
delete;
field ( readonly ) BookId;
field ( numbering : managed ) BookId;
validation validateIsbn on save { field Isbn; }
action markAsRead result [1] $self;
}

Difference: RAP is central in ABAP Cloud, optional in Classic ABAP.


5. Performance

Classic ABAP

Possible Performance Issues:

  • SELECT in loops (common)
  • No built-in optimizations
  • Manual tuning required

Example Problem:

LOOP AT lt_customers INTO DATA(ls_customer).
" SELECT in loop - very slow!
SELECT SINGLE * FROM kna1
WHERE kunnr = ls_customer-id
INTO @DATA(ls_detail).
ENDLOOP.

ABAP Cloud

Performance Advantages:

  • CDS Views with automatic optimizations
  • RAP Framework optimizes DB access
  • Built-in caching
  • EML batches operations automatically

Example Solution:

" One SELECT for all IDs
SELECT FROM I_Customer
FIELDS Customer, CustomerName
FOR ALL ENTRIES IN @lt_customers
WHERE Customer = @lt_customers-id
INTO TABLE @DATA(lt_details).

Difference: ABAP Cloud enforces best practices, Classic ABAP allows bad patterns.


6. Testing

Classic ABAP

Unit Testing:

  • ABAP Unit available
  • But often not used
  • No Test Seam Framework
CLASS ltc_test DEFINITION FOR TESTING.
PRIVATE SECTION.
METHODS test_calculation FOR TESTING.
ENDCLASS.
CLASS ltc_test IMPLEMENTATION.
METHOD test_calculation.
DATA(lv_result) = zcl_calculator=>calculate( 10 ).
cl_abap_unit_assert=>assert_equals(
act = lv_result
exp = 12 ).
ENDMETHOD.
ENDCLASS.

ABAP Cloud

Unit Testing:

  • ABAP Unit recommended
  • CDS Test Double Framework
  • RAP Test Seams
CLASS ltc_test DEFINITION FOR TESTING.
PRIVATE SECTION.
CLASS-DATA environment TYPE REF TO if_cds_test_environment.
CLASS-METHODS class_setup.
METHODS test_create_book FOR TESTING.
ENDCLASS.
CLASS ltc_test IMPLEMENTATION.
METHOD class_setup.
environment = cl_cds_test_environment=>create_for_multiple_cds(
i_for_entities = VALUE #( ( i_for_entity = 'ZI_BOOK' ) )
).
ENDMETHOD.
METHOD test_create_book.
MODIFY ENTITIES OF zi_book
ENTITY Book CREATE FROM VALUE #( ( %cid = 'B1' Title = 'Test' ) ).
" Test assertions
ENDMETHOD.
ENDCLASS.

Difference: ABAP Cloud has better testing tools and testing is culturally more important.


7. Deployment & DevOps

Classic ABAP

Deployment:

  • Transports (DEV → QAS → PRD)
  • Manual releases
  • Little CI/CD

Version Control:

  • abapGit optional
  • Often no Git

ABAP Cloud

Deployment:

  • Transports + seamless abapGit
  • CI/CD Pipelines (ABAP Environment Pipelines)
  • Continuous deployment possible

Version Control:

  • abapGit recommended
  • Git integration in ADT

Example CI/CD Pipeline:

# Azure DevOps / GitHub Actions
- name: Run ABAP Unit Tests
run: abap test --package ZBOOK
- name: Deploy to QAS
run: abap deploy --target QAS
- name: Run Integration Tests
run: abap integration-test

Difference: ABAP Cloud is DevOps-friendlier.


8. When to Use Which Version?

Use Classic ABAP when:

  • You have on-premise SAP ECC/S/4HANA
  • Legacy code needs to be maintained
  • Migration to ABAP Cloud (not yet) planned
  • You need to work with Dynpro
  • Short to medium-term projects (<5 years)

Example Scenarios:

  • Maintenance of existing reports
  • Quick customizations to standard code
  • Projects with tight budget/time

Use ABAP Cloud when:

  • Starting new development
  • Cloud deployment planned (SAP BTP)
  • Long-term maintainability important (>5 years)
  • Following Clean Core strategy
  • Modern development (RAP, Fiori)

Example Scenarios:

  • New SAP Fiori apps
  • S/4HANA Cloud projects
  • Greenfield development
  • SaaS applications on SAP BTP

9. Learning Curve

Classic ABAP

Learning Effort: Medium

Getting Started:

  1. ABAP basics (2-4 weeks)
  2. Internal tables, selects (2 weeks)
  3. Dynpro/reports (2-3 weeks)
  4. BAPIs, RFCs (1-2 weeks)

Total: ~3 months until productive

ABAP Cloud

Learning Effort: High

Getting Started:

  1. Modern ABAP syntax (2 weeks)
  2. CDS Views (3-4 weeks)
  3. RAP (6-8 weeks)
  4. SAP Fiori (4-6 weeks)
  5. Testing & DevOps (2 weeks)

Total: ~5-6 months until productive

However: Long-term better maintainability!


10. Migration: Classic → Cloud

Migration Path

Classic ABAP
Modernize (ABAP Cleaner, new syntax)
Identify Released APIs
ABAP Cloud-compliant new development
Step-by-step migration
ABAP Cloud ✓

Tools:

  • Custom Code Migration App (Fiori App)
  • ABAP Test Cockpit (ATC Checks)
  • ABAP Cleaner (syntax modernization)

See: ABAP Cloud Migration Guide


11. Costs

Classic ABAP

License Costs:

  • On-premise license (one-time + maintenance)
  • No cloud costs

Developer Costs:

  • Average ABAP developer: €60-80k/year

ABAP Cloud

License Costs:

  • SAP BTP: Pay-per-use (from ~€200/month)
  • Or: S/4HANA Cloud (higher license costs)

Developer Costs:

  • ABAP Cloud developer: €70-90k/year (higher demand)

Long-term: ABAP Cloud often cheaper through:

  • Less maintenance effort
  • Automatic upgrades
  • Lower infrastructure costs (cloud)

12. Summary: Decision Matrix

CriterionClassic ABAPABAP CloudWinner
Entry barrierLowHighClassic
Long-term maintainabilityMediumHighCloud
PerformanceGoodVery goodCloud
Upgrade stabilityLowVery highCloud
FlexibilityVery highMediumClassic
Cloud-readyNoYesCloud
UI modernityMedium (Dynpro old)High (Fiori only)Cloud
Developer experienceGoodVery good (ADT)Cloud
Community/resourcesVery largeGrowingClassic
Future-proofMediumVery highCloud

Conclusion:

  • Short-term: Classic ABAP faster & more flexible
  • Long-term: ABAP Cloud more maintainable & future-proof

Further Resources

On abapcloud.com:

External Resources:


Your Opinion?

  • Do you develop with Classic ABAP or ABAP Cloud?
  • Are you planning a migration?
  • What do you miss in ABAP Cloud?

Share your experiences in the comments!

Good luck with your decision!