Knowledge quiz

It's time to put what you've learned to the test, get 8 right to pass this unit.

1.

Assume you want to define an Authors entity as a projection on the db.Authors entity from the domain model. All elements of the db.Authors domain entity are to be included in the projection with the exception of the books element. Which of the following syntax variants is the correct one to achieve this?

Choose the correct answer.
2.

The easiest way to add custom service implementations is to place an equally named .js file next to the .cds file that contains the respective service definition. As an alternative to this approach, which annotation can you use to explicitly reference the service definition in the .cds file to another .js file that should contain the service implementation?

Choose the correct answer.
3.

What are after event handlers normally used for?

Choose the correct answer.
4.

Suppose you use the @assert.range annotation to specify a value range for an element of an entity. What happens if a value outside the defined range is provided during a CREATE operation?

Choose the correct answer.
5.

What is the expected outcome when a PUT request is made with an outdated ETag value?

Choose the correct answer.
6.

Is the following statement regarding the difference between actions and functions correct? Functions modify data on the server, actions retrieve data.

Choose the correct answer.
7.

The cds.ql module exposes an SQL-like API for constructing database queries. Which of the following are names of global objects provided by the cds.ql module for query construction?

There are two correct answers.
8.

What kinds of event handlers are available in CAP that can be registered for different phases during the processing of an event?

There are three correct answers.
9.

Assuming you have constructed a query object q. How is the query executed on the database? 

There are two correct answers.
10.

What is the @assert.target annotation used for in CAP?

Choose the correct answer.