SAP ABAP Dictionary Interview Questions With Answers-3



11) What Is A Database View?

The database view is combining several fields of two or more tables into single table. At least one relationship is required is required to combine tables to build a database view. Plus one can only read data from database view and cannot modify the data in the view directly (if view involves more than one table). Database views implement an Inner Join on the tables. The database view is the only type of view in SAP that is physically created at the database level.

For example, consider two tables T1, T2.

Fields of table T1 are F1, F2 and F3. Fields of table T2 are F1, F5.

By using a Database view one can combine the fields of both tables T1 and T2, provided primary and foreign key relation is maintained between the two tables and thus final view can have fields like F1, F2, F3, F5.

For more information: http://www.saptechnical.com/Tutorials/ABAP/View/Database.htm


12) What Is A Projection View?

In standard SAP tables one can find there are a number of fields. Sometimes it happens or there is a requirement of viewing only a fewer no of fields of a table, in such cases a projection view can be created. Projection views are created only on a single table.

For example, if Table T1 has fields F1,F2,F3,F4,F5, F6, F7, F8, F9, F10, etc…

Say there is a need to view data only for say Fields F1, F2, F4,F8 & F9, in such cases projection view can be created.

For more information: http://www.saptechnical.com/Tutorials/ABAP/View/Page2.htm


13) What Is A Maintenance View?

Just like we have table maintenance (SM30) for each table, similarly if there is a requirement to maintain data for one or more tables in a single view, then maintenance view can be created. All the tables in a maintenance view must be linked with foreign key. The join conditions for maintenance views are always derived from the foreign key automatically and thus one cannot directly enter the join conditions as for database views. Unlike Database views, one can modify data from maintenance view.

Thus, a maintenance view allows you to maintain the data of an application object together.

For more information: http://freesapabap.blogspot.in/2013/07/creation-of-maintenance-view.html


14) What Is A Help View?

Help views can be used as selection methods for Search Helps. It might be necessary to create a Help View if you are trying to accomplish an outer join, since database views only create inner joins.

For more information: http://freesapabap.blogspot.in/2013/07/creation-of-maintenance-view.html


15) State The Differences Between Database View & Projection View?

The basic differences between projection view and database view are:
  • Database view can built over many tables whereas projection view can be built over a single table only.
  • Database view can be updated if the view is built over a single table whereas in projection view data can be updated.
  • In case of database view, data updates can use open SQL or native SQL whereas in case of projection view, data updates must use open SQL.
  • Database view can be buffered whereas Projection view cannot be buffered.

16) What Are The Relational Operations That Can Be Performed On View In SAP?

There are three operations that can be performed on views in SAP: Join, Projection and Selection.
  • The Projection Operation is used to narrow a view’s focus to certain fields in a table.
  • The Selection Operation is used to narrow a view’s focus to certain records in a table.
  • The Join Operation is used to combine information from multiple tables into a single view.


No comments:

Post a Comment