A projection view is a special view for hiding fields from a single basis table. An SQL view is not created on the database. No selection conditions can be specified for a projection view.
The structure type defined using the view fields of the projection view can be referenced in ABAP programs
TYPE. A projection view can be accessed using Open SQL but not Native SQL. Projection views can be used to access
pooled table or cluster tables as well
as transparent tables. The database interface transforms an Open SQL statement that accesses a projection view to a platform-specific SQL statement that provides the correct result.
The Access setting in the maintenance status of a projection view can have the following values:
- Read only
- Read, change, delete, and insert
When rows are inserted using projection views, all table fields not in the view are given the type-specific initial values of the field. This is done regardless of whether the fields is defined as NOT NULL on the database.
7.31 | 7.40 | 7.54
Like a database table, the maintenance status of a projection view has a Display and Maintain setting alongside the Access setting. The setting must match the Access setting.
The projection view DEMO_SPFLI contains fields of the tables SPFLI. The view could be accessed as follows using Open SQL:
SELECT * FROM demo_spfli ORDER BY carrid, connid INTO TABLE @DATA(result). cl_demo_output=>display( result ).