Applying dynamic Open SQL

The Open SQL statement components may be specified statically or dynamically. This applies to database read statement SELECT, as well as data manipulation statements such as INSERT and UPDATE. The primary emphasis of this recipe will be on dynamic specifications of the various components of the SELECT statement. The previous recipe saw some usage of the dynamic SQL in the SELECT statement, where the table name, the target area internal table (pointed to by a field symbol), and the number rows to read using UP TO addition were specified dynamically. In addition to these, the GROUP BY, the ORDER BY, and WHERE conditions may be specified dynamically.

In this recipe, we will create a program that will take input from the user ...

Get SAP ABAP Advanced Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.