Want to learn ABAP for FREE with direct access to community of students and ABAP experts?

Sign up now!

Category: ABAP

Useful ABAP code snippets that can be used in real life projects.

Programming error ASSERTION_FAILED CL_SLIN_CHECKER_SINGLE========CP BC-ABA-LA The Assert Condition was violated.

Problem: When running Extended Syntax Checker, you get the following runtime error:  

How to download records from database table into CSV file?

When you need to download records from database table into CSV file, you need to tweak a bit around to get the final file, because SAP does not provide straightforward function on how to do it. So, how to download records from database table into CSV file? Here is how you do it.

How to change record in database table using debugger?

Sometimes you need to change specific database record but you don’t have ability to edit record in database directly using edit button, because database table has defined Delivery and Maintenance parameter to ‘Display/Maintenance Not Allowed’. In such case you can do the small hack using Debugger. How to change record in database table using debugger?

Index is not Used in SELECT

If you realize that index is not used in select, you need to force database to use it. For this, you need to use database hints in your code.  Hints depend on database server. In the following example, here is how to force database to use index when using SAP Trial system (with MaxDB): SELECT *       FROM zaa_bd_wpo_vol...

How to Run ABAP Program in Background Manually? (Easy Way)

Sometimes your program may contain logic that must run long time. In such case, you can’t easily run it by pressing ‘Execute’ program, because SAP has defined maximum number of seconds that is able to run any programs this way (it’s called foreground processing). In such case, you must execute the program differently. You have...

How to Run ABAP Program in Background Manually?

Sometimes your program may contain logic that must run long time. In such case, you can’t easily run it by pressing ‘Execute’ program, because SAP has defined maximum number of seconds that is able to run any programs this way (it’s called foreground processing). In such case, you must execute the program differently. You have...

Hello World! in ABAP for SAP Developers

Do you want to create your first ABAP program? Watch this video ” Hello World in ABAP for SAP Developers” and learn it by yourself. If you need a system, where you can practice your ABAP knowledge, download instructions on how to install your free local SAP system here: http://abapacademy.com/howtoinstallsaptrial/

How to trigger DATA_CHANGED event in CL_GUI_ALV_GRID

If you have problem getting changed data in ALV from DATA_CHANGED event, you must do the following:

Get class or interface definition information

Get information of class definiton: SEO_CLASS_TYPEINFO_GET Get information of interface definiton: SEO_INTERFACE_TYPEINFO_GET Get method definiton: SEO_METHOD_SIGNATURE_GET

Exit screen when obligatory fields are not filled

Define function button in GUI status with functional type ‘E’ – Exit command. In Process after input call module at exit command as follows: PROCESS AFTER INPUT.MODULE cancel AT EXIT-COMMAND. And implement module: MODULE cancel INPUT.* Just leave the screen without checking any obligatory fields  LEAVE TO SCREEN 0.ENDMODULE. ” CANCEL_POPUP INPUT