Implementing Database Updates Using Business Objects Flashcards

1
Q

What is a business object in the ABAP RESTful application programming model?

A

A business object defines an entity, like a travel agency, with CDS views defining its structure and behavior definitions specifying operations like create, update, and delete, along with validations and actions.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What does the behavior definition of a business object describe?

A

the allowed standard operations (e.g., create, update, delete) and defines checks (validations) performed when data is created or changed.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What does the behavior implementation of a business object contain?

A

The actual specific code for validations, determinations, and actions, as well as code for standard operations depending on the implementation scenario.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

How is the behavior implementation of a business object structured?

A

The behavior implementation consists of one or more ABAP classes. The global class is declared in the behavior definition, and the actual coding is contained in a local class within the global class definition.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What is a validation in the context of a business object?

A

A validation is a check performed by the runtime when data is changed. It ensures data correctness during record creation or modification based on defined triggers and conditions.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What is the purpose of the behavior definition’s link to the database table?

A

The link between the behavior definition and the database table specifies how the data is stored and managed, including information about active data, drafts, locking, authorization checks, and concurrency control.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What is the behavior pool in the context of a business object?

A

The behavior pool refers to the global class that serves as the container for the behavior implementation of a business object. It is declared in the behavior definition and contains the actual coding specific to the business object’s behavior.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What is a Business Service in the ABAP RESTful application programming model?

A

A Business Service is a way to consume a Business Object, typically through an OData UI Service for an SAP Fiori Application.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What is Entity Manipulation Language (EML)?

A

a set of ABAP statements used to access Business Objects from inside ABAP code.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Why should a Business Object not be consumed directly?

A

consumers should access Business Object Projections (BO Projections) and Business Object Interfaces (BO Interfaces) to ensure stability and encapsulation.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What is a BO Projection?

A

a service-specific projection of a Business Object, specifying a subset of its data and operations available through the service.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

What is a BO Interface?

A

A BO Interface provides stable access to a Business Object’s data and operations, typically released for use in other software components. Accessing a BO Interface is recommended for ABAP code using EML.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

How can you identify a BO Projection or BO Interface?

A

BO Projections start with the keyword “projection” in their behavior definitions, while BO Interfaces start with the keyword “interface”.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

What is the naming convention for BO Projections, BO Interfaces, and BO Definitions in SAP developments?

A

BO Projections <namespace>C_<...>,</namespace>

BO Interfaces <namespace>I_<...></namespace>

BO Definitions <namespace>R_<...>.</namespace>

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

What is EML?

A

EML, or Entity Manipulation Language, consists of statements used to manipulate the data of a business object.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

How do you read data from a business object using EML?

A

To read data from a business object, you use the READ ENTITIES statement, specifying the keys of the data you want to read and the results of the query.

17
Q

What are the key components of the READ ENTITIES statement?

A

The READ ENTITIES statement includes parameters for the keys of the data to be read and the result set, along with the addition of fields to specify which fields of the business object are required.

18
Q

What is the purpose of the TYPE TABLE FOR READ IMPORT in EML?

A

The TYPE TABLE FOR READ IMPORT contains the key field(s) of the business object and %control structure to indicate which fields are used in the operation.

19
Q

How is data updated in a business object using EML?

A

Data is updated using the MODIFY ENTITIES statement with the UPDATE addition, specifying the fields to be changed and the internal table containing the updated data.

20
Q

What is the function of the COMMIT ENTITIES statement in EML?

A

The COMMIT ENTITIES statement triggers the save sequence to persist data changes made outside the business object in the database, but it’s not necessary nor allowed inside the behavior implementation of the business object.

21
Q

What operations can be performed using EML?

A

EML supports operations such as reading data with the READ ENTITIES statement and modifying data with the MODIFY ENTITIES statement (UPDATE, CREATE, DELETE).

22
Q

What determines the operations that can be performed with EML?

A

The operations allowed by EML depend on the behavior definition of the business object interface. Direct usage of prohibited operations results in syntax errors.

23
Q

How are internal tables declared in EML?

A

Internal tables are declared using the TYPE TABLE FOR <operation> addition in the DATA statement, where <operation> specifies the operation (e.g., READ IMPORT, READ RESULT, UPDATE).</operation></operation>

24
Q

What is contained in the TYPE TABLE FOR READ RESULT in EML?

A

The TYPE TABLE FOR READ RESULT contains all fields of the business object and is used to hold the result set after executing a READ ENTITIES statement.

25
Q

How is data updated in the transactional buffer using MODIFY ENTITIES in EML?

A

Data is updated in the transactional buffer using MODIFY ENTITIES with the UPDATE addition, specifying the fields to be changed and the internal table containing the updated data.

26
Q

In our scenario, what is coded in a behavior implementation?

Determinations
Validations
Update

A

Determinations
Validations

That’s right. Validations and determinations are coded in the behavior implementation. But In the managed implementation scenario, the framework takes care of the standard operations create, update and delete.

27
Q

What does the TYPE TABLE FOR UPDATE declaration represent in EML?

A

TYPE TABLE FOR UPDATE is a special data type used to declare internal tables in EML, representing data to be updated in the transactional buffer. It contains all fields of the business object along with the %control structure.