SAP Architect ABAP Core Interview Questions

ABAP Core is a standard block in SAP Architect interviews. It is rarely asked as a definition; it is asked as a situation you have to talk your way through.

Master the foundation of ABAP programming: program structure, variables, system fields, selection screens, validations, messages, exceptions and clean coding basics.

This page carries 18 reviewed SAP Architect abap core interview questions, each with a complete written answer and no sign-in required. The set breaks down into 5 foundational, 8 mid-level and 5 advanced questions, so you can start at the top for a first interview or skip ahead to the scenario-based items for a senior round.

Treat the answers as a starting structure, not a script. Interviewers in SAP Architect rounds follow up on whatever you sound least certain about, so the value is in being able to keep going after the first answer.

18 ABAP Core questions with answers

easyABAP Core

1. Explain the difference between static and instance methods, and when you would prefer each in a real object-oriented ABAP class.

Static methods (CLASS-METHODS) belong to the class and cannot access instance data; instance methods act on a specific object via me->. Use static for stateless helpers (formatting, lookups) and factory methods; use instance methods when the behavior depends on object state such as a document header currently being processed. Static state should be avoided because it survives across transactions in the same work process and can leak data between users.
easyABAP Core

2. Explain the difference between TYPE and LIKE in ABAP.

TYPE refers to a data type defined in the ABAP Dictionary or in a TYPES statement. LIKE refers to an existing data object (variable/structure). Modern ABAP recommends TYPE because it decouples the declaration from a specific variable and works with dictionary types that carry conversion exits and F4 help.
easyABAP Core

3. What are the elementary data types in ABAP and which one is best for money?

Elementary types include C, N, D, T, P, I, F, STRING and XSTRING. For currency and quantities use P (packed decimal) with the appropriate DECIMALS or the dictionary types CURR/QUAN, because they preserve precision and interact correctly with currency-conversion logic.
easyABAP Core

4. What are field symbols and when should you use them?

A field symbol is a typed pointer to a data object. It avoids copying data – changes to the field symbol change the underlying variable. Common uses: LOOP AT itab ASSIGNING FIELD-SYMBOL(<fs>) to modify rows in place (faster than INTO WA + MODIFY), dynamic access with ASSIGN COMPONENT ... OF STRUCTURE, and generic programming with typed / untyped field symbols. Always check <fs> IS ASSIGNED before use.
easyABAP Core

5. Explain string templates in ABAP and how they help avoid classic string concatenation bugs.

String templates use |...{ var }...| to embed variables directly, with formatting options such as ALPHA, DATE, TIME, NUMBER. They eliminate the need for CONCATENATE chains and manual leading-zero handling, and they preserve type-safe conversion using the field's declared type. This reduces bugs where leading zeros get stripped from customer numbers or amounts lose scale.
mediumABAP Core

6. A LOOP is slow on a 500k-row internal table. How do you speed it up?

Use FIELD-SYMBOLS with ASSIGNING to avoid copying each row, define a SORTED or HASHED table with a matching key, add secondary keys for alternative lookups, and use BINARY SEARCH on sorted standard tables. Consider processing the data in the database with Open SQL instead of the application server.
mediumABAP Core

7. A junior developer wrote a class that opens a database cursor in the constructor and never closes it. What are the risks and how would you refactor it?

Cursors held for the object lifetime can lock DB resources, exhaust cursor limits, and prevent parallel processing; if the object is kept in a shared buffer the leak persists across dialog steps. Refactor so the cursor is opened only when needed inside a specific method, wrapped in a TRY / CLEANUP block that CLOSE CURSORs on error, and closed explicitly in the same scope. Prefer a single SELECT / SELECT ... INTO TABLE where feasible.
mediumABAP Core

8. You need to build a report that reads flight bookings, applies business rules, and outputs an ALV. Describe the modularisation you would choose and why.

Split into: (1) selection screen event block, (2) a data access class or function group with strongly-typed methods (get_bookings, apply_rules), (3) a view/output class that receives an already-computed internal table and shows CL_SALV_TABLE. Keep DB reads, business logic, and UI separated so the report can be reused as a batch job or wrapped by an OData service without changes. Avoid FORM/PERFORM subroutines in new code.
mediumABAP Core

9. Amount fields show wrong values after arithmetic. What went wrong?

Most likely the field was declared as I or F, or two P fields with different DECIMALS were combined without ROUNDING. Redeclare using dictionary type CURR with the correct currency reference, or P LENGTH n DECIMALS 2 aligned to the currency's decimals, and always carry the currency key next to the amount.
mediumABAP Core

10. Difference between STANDARD, SORTED and HASHED tables.

STANDARD is sequentially indexed and best for append-and-loop scenarios. SORTED maintains order by a defined key and supports fast binary access. HASHED gives O(1) READ by unique key but does not support index access or ranges. Choice depends on the access pattern.
mediumABAP Core

11. What is the difference between VALUE #( ), NEW #( ) and CORRESPONDING #( ) in modern ABAP? Give a practical example for each.

VALUE #( ) constructs structures/tables inline using the target type; useful to build a small itab literal or a return structure. NEW #( ) creates an object instance with inferred type; typically used with data references or to instantiate a helper class in one line. CORRESPONDING #( ) copies fields by name between structures or tables, with MAPPING / EXCEPT clauses for renaming; used when moving data between DB tables and API structures without hand-coded MOVE-CORRESPONDING chains.
mediumABAP Core

12. When would you choose a Function Module over a global class, and vice versa, on an S/4HANA project today?

Prefer global classes for new code: unit-testable, inheritable, easier to mock, and align with clean-core. Use function modules when the caller must be RFC-enabled, when integrating with legacy update tasks (CALL FUNCTION ... IN UPDATE TASK), or for BAPI-style released APIs where the RFC signature is the contract. Wrap RFC-only interfaces in a thin FM that delegates to a class so logic stays testable.
mediumABAP Core

13. Describe how ABAP exceptions differ from classical sy-subrc handling and how you would design exception classes for a payments module.

Class-based exceptions carry typed context (attributes, texts, T100 keys), can be caught by hierarchy, and force the caller to acknowledge them with TRY / CATCH or RAISING. Design a base exception for the module (e.g. ZCX_PAYMENTS) inheriting from CX_STATIC_CHECK, then specific subclasses (ZCX_PAYMENTS_NO_AUTH, ZCX_PAYMENTS_LIMIT_EXCEEDED) so callers can react selectively. Attach previous exceptions to preserve the cause chain instead of swallowing them.
hardABAP Core

14. How do you design an ABAP class that must be safely enhanced by other teams later without breaking your code?

Mark the class as CREATE PROTECTED or FINAL depending on intent, keep attributes PRIVATE with accessor methods, expose stable public interfaces (INTERFACES) instead of raw methods, use BADIs or explicit enhancement spots for controlled extension points, and version the interface. Follow Liskov: any subclass should be usable through the parent reference without surprises. Document expected preconditions and side effects.
hardABAP Core

15. How do you decide between a report, a Fiori app or a background job?

Reports fit ad-hoc power-user use with rich ALV. Fiori apps fit process-driven end users who need role-based tiles and mobile. Background jobs fit scheduled or event-driven processing without a UI. Volume, frequency, user role and integration with S/4 workflow all drive the choice.
hardABAP Core

16. You are the ABAP architect for a green-field S/4HANA migration from ECC. Which old ABAP patterns would you deprecate and what would you enforce for new developments?

Deprecate: FORM/PERFORM, includes as logic containers, native SQL, direct writes to standard tables, header lines on internal tables, and modifications to SAP code. Enforce: released APIs only (clean core), CDS + Open SQL for reads, BOPF / RAP for transactional logic, ADT with abapGit for versioning, unit tests with ABAP Unit + test doubles, static checks via ATC with the S/4 readiness variant, and 7.5x language features (inline declarations, string templates, table expressions).
hardABAP Core

17. How do you profile a slow ABAP program in production?

Use SAT (runtime analysis) on a representative user scenario, ST05 SQL trace to isolate database hot spots, ST12 (single-transaction analysis) for combined ABAP+SQL, and STAD to find worst dialog steps. Correlate SAT hierarchy with ST05 identical statements to decide whether to tune ABAP or SQL.
hardABAP Core

18. How would you refactor a 4000-line report into maintainable code?

Extract data selection into a separate class method, move business logic into stateless service classes, use local test doubles for the database layer, split output into a dedicated ALV builder, and add unit tests around the logic classes. Keep the report a thin orchestrator.

Related lesson

ABAP Program Structure and Runtime Flow

Related topics

Next practice step