Video Lesson 4.8: ABAP IF statement and CASE

Video Lesson 4.8: ABAP IF statement and CASE

This lesson shows how to use the IF statement and the CASE statement for conditioning.

  • In ABAP you have two ways to execute different sequences of statements, depending on certain conditions:
  • In the IF construct you can define any logical expressions as check conditions.
  • You can use nested IF statements, using the ELSEIF clause.
  • You can use the CASE construct to clearly distinguish cases.
  • The content of the field specified in the CASE part is checked against the data objects listed in the WHEN branches to see whether they match.

  • In both constructs the condition or match check happens sequentially from the top down.
  • As soon as the statement block of a branch has been executed, the system immediately jumps to ENDIF or ENDCASE.



Share this on Social Media

Facebook
Twitter
LinkedIn
Pinterest
WhatsApp

Unit 1 – SAP System Architecture

Unit 2 – Object Navigator, Repository and ABAP Programs

Unit 3 – Transparent tables in the ABAP Dictionary

Unit 4 – Basic ABAP statements, ABAP Structures and ABAP Logical Expressions

Unit 5 – ABAP Data Retrieval

Unit 6 – SAP Analysis Tools

Unit 7 – ABAP Subroutines

Unit 8 – ABAP Events

Unit 9 – ABAP User Interface

Unit 10 – Function Modules, Methods, ALV and BAPI

Unit 11 – Adjusting SAP Standard Software

Unit 12 – ABAP Debugger, Selection Screens, and Table Controls

Unit 13 – ABAP Web Dynpro

Unit 14 – Advanced Topics

Unit 15 – Advanced Topics II

Object Oriented (OO) ABAP

ABAP for SAP HANA (Introduction)

OData and SAP Netweaver Gateway