SAP C_HANADEV_18 SAP Certified Development Associate - SAP HANA 2.0 SPS06 Exam Practice Test

Page: 1 / 14
Total 95 questions
Question 1

To perform a specific task of an XS advanced application, what does a user need? Please choose the correct answer.



Answer : A

According to the SAP HANA Developer Guide, to perform a specific task of an XS advanced application, a user needs to have directly assigned a role collection. A role collection is a set of roles that grant the user the necessary privileges and authorizations to access and use the application. A role collection can be assigned to a user either directly by an administrator, or indirectly by a workflow or a self-service. The other options are incorrect, because:

To have directly assigned a scope is not a way to perform a specific task of an XS advanced application, but a way to limit the access of a user to a subset of resources within an application. A scope is a qualifier that can be added to a role to restrict the user's access to a specific resource, such as a space, an organization, or a service instance. A scope does not grant any privileges or authorizations by itself, but only modifies the existing ones.

To be assigned to an organization is not a way to perform a specific task of an XS advanced application, but a way to group users and resources in a logical unit. An organization is a container that holds spaces, users, applications, and services. An organization can have one or more spaces, which are isolated environments for developing, deploying, and running applications. A user can belong to one or more organizations, but can only perform tasks in the spaces that they are assigned to.

To be assigned to a space is not a way to perform a specific task of an XS advanced application, but a way to access a specific environment for developing, deploying, and running applications. A space is a sub-container within an organization that holds applications and services. A space can have one or more users, who can have different roles and permissions depending on their tasks. A user can belong to one or more spaces within an organization, but can only perform tasks in the spaces that they are assigned to.


Question 2

You need to combine data from different database tables within your OData service. Which capability do you use for this relationship? Please choose the correct answer.



Answer : C

An OData service is a web service that exposes data from a data source, such as a SAP HANA database, in a standardized and interoperable format. An OData service consists of one or more entity sets, which are collections of entities of the same type. An entity is a data object that has properties and a unique key. An OData service can also define associations between entity sets, which are relationships that specify how entities are related to each other. For example, an association can define a one-to-many or a many-to-many relationship between two entity sets. Associations enable an OData service to combine data from different database tables within the same service. For example, an OData service can define an association between a Products entity set and a Categories entity set, where each product belongs to one category and each category can have multiple products. This association can be used to query or update data from both entity sets in a single request.

The other options are incorrect because they are not capabilities that can be used to combine data from different database tables within an OData service. Aggregations are operations that summarize or group data, such as count, sum, average, or min/max. Projections are operations that select or filter data, such as select, expand, or filter. Entity sets are collections of entities of the same type, but they do not define relationships between entities.Reference:

SAP HANA Platform 2.0 SPS06: OData V4 Developer Guide, Section 2.1

SAP HANA Platform 2.0 SPS06: OData V4 Developer Guide, Section 2.3

SAP HANA Platform 2.0 SPS06: OData V4 Developer Guide, Section 2.4

SAP HANA Platform 2.0 SPS06: OData V4 Developer Guide, Section 2.5

SAP HANA Platform 2.0 SPS06: OData V4 Developer Guide, Section 2.6


Question 3

You develop a Node.js application for the SAP HANA platform that executes a SQL statement in the SAP HANA database. Which modules

do you use?

There are 2 correct answers to this question.



Answer : B, C

To develop a Node.js application for the SAP HANA platform that executes a SQL statement in the SAP HANA database, you need to use the following modules:

@sap/xsenv: This module provides functions to load service configuration and credentials from the environment variables of the SAP Cloud Platform or the SAP HANA XS Advanced Model. You can use this module to access the SAP HANA database service information, such as host, port, user, password, and schema.

@sap/hdbext: This module provides a wrapper for the SAP HANA client for Node.js, which enables you to connect to the SAP HANA database and execute SQL statements. You can use this module to create a database connection pool, execute queries, fetch results, and handle errors.

The other options are not correct because:

A) @sap/instance-manager: This module provides functions to manage the lifecycle of Node.js applications running on the SAP Cloud Platform or the SAP HANA XS Advanced Model. You can use this module to start, stop, restart, scale, and monitor your applications, but not to execute SQL statements in the SAP HANA database.

D) @sap/node-vsi: This module provides functions to interact with the SAP HANA Virtual Schema Integrator (VSI), which enables you to access data from remote sources using virtual tables. You can use this module to create, update, delete, and query virtual tables, but not to execute SQL statements in the SAP HANA database.


SAP HANA Developer Guide for SAP HANA Web IDE, Chapter 5, Section 5.2

SAP HANA Developer Guide for SAP HANA Web IDE, Chapter 5, Section 5.3

SAP HANA Developer Guide for SAP HANA Web IDE, Chapter 5, Section 5.4

SAP HANA Developer Guide for SAP HANA Web IDE, Chapter 5, Section 5.5

Question 4

What is the package descriptor package.json used for? There are 2 correct answers to this question.



Answer : C, D

The package descriptor package.json is a JSON file that defines the build, deployment, and runtime dependencies of a JavaScript application in SAP HANA XS Advanced. The package.json file is mandatory for JavaScript applications and it is located in the general section of the project. As well as the application name and version, dependencies to other Node.js modules, the Node.js version, run scripts, and the main program are configured. The package descriptor package.json is used for the following purposes:

To list the package dependencies: The package.json file contains a dependencies property that lists the names and versions of the Node.js modules that the application depends on. These modules are installed by the npm install command during the build process and are available in the node_modules folder of the application. The dependencies property can also specify the scope and type of the dependencies, such as devDependencies for development-only modules, or peerDependencies for modules that are required by other modules.

To define the routes: The package.json file contains a sap.cloud.service property that defines the name of the service that the application provides or consumes. This name is used to generate the routes for the application in the XS advanced environment. The routes are defined in the xs-app.json file, which is located in the same folder as the package.json file. The routes specify the rules for forwarding requests to the back-end microservices or destinations.

The following purposes are not achieved by the package descriptor package.json, but by other files or tools:

To define back-end destinations: The back-end destinations are defined in the mta.yaml file, which is the deployment descriptor file that specifies the metadata and dependencies for the multi-target application (MTA) project. The mta.yaml file is located in the root folder of the MTA project and is used by the Cloud Foundry environment to deploy the application. The back-end destinations are declared as resources of type org.cloudfoundry.existing-service or org.cloudfoundry.managed-service, and are bound to the application modules by the requires property.

To set the router version: The router version is set by the @sap/approuter module, which is a Node.js module that provides the application router service for the XS advanced environment. The application router service is responsible for routing requests to the appropriate destinations and for authenticating users. The @sap/approuter module is installed by the npm install command during the build process and is available in the node_modules folder of the application. The version of the @sap/approuter module is specified in the dependencies property of the package.json file.


[SAP HANA Deployment Infrastructure Reference], Chapter 5: HDI with XS Advanced, Section 5.1: Developing with the SAP Web IDE for SAP HANA, Subsection 5.1.2: Configure Application Routing (xs-app.json), pp. 101-104.

[SAP HANA Platform Documentation], SAP HANA Developer Guide for SAP HANA XS Advanced Model, Chapter 4: Developing HTML5 Applications, Section 4.1: Developing HTML5 Applications Using SAP Web IDE for SAP HANA, Subsection 4.1.3: Configure Application Routing (xs-app.json), pp. 77-80.

Question 5

What key words are contained in the application descriptor file (xs-app.json)? There are 2 correct answers to this question.



Answer : A, D

The application descriptor file (xs-app.json) is a JSON file that defines the routing and authentication configuration for an HTML5 module in a multi-target application (MTA) project. It is located in the root folder of the HTML5 module and is used by the managed application router to dispatch requests to the appropriate destinations and to authenticate users. Some of the key words that are contained in the xs-app.json file are:

routes: This is an array of objects that specify the rules for forwarding requests to the back-end microservices or destinations. Each route object has a source property that defines a regular expression to match the request path, and a destination property that defines the name of the destination to which the request should be forwarded. Optionally, a route object can also have other properties, such as authentication, csrfProtection, service, or scope, to further configure the routing behavior.

authenticationMethod: This is a property that defines the authentication method to be used for the HTML5 module. It can have one of the following values: route, which means that the authentication method is defined by the route configuration; none, which means that no authentication is required; or approuter, which means that the authentication is delegated to the approuter service. The authenticationMethod property can be set at the global level for the entire HTML5 module, or at the route level for a specific route.

The following key words are not contained in the xs-app.json file, but in other files related to the MTA project:

role-templates: This is an array of objects that define the roles and their corresponding scopes and attributes for the application. The role-templates are defined in the xs-security.json file, which is the application security descriptor file that specifies the security configuration for the application. The xs-security.json file is located in the root folder of the db module and is used by the User Account and Authentication (UAA) service to manage the authorization and trust management for the application.

tenant-mode: This is a property that defines the tenant mode for the application. It can have one of the following values: dedicated, which means that the application runs in a dedicated schema for each tenant; shared, which means that the application runs in a shared schema for all tenants; or mixed, which means that the application runs in a mixed mode depending on the tenant context. The tenant-mode property is defined in the mta.yaml file, which is the deployment descriptor file that specifies the metadata and dependencies for the MTA project. The mta.yaml file is located in the root folder of the MTA project and is used by the Cloud Foundry environment to deploy the application.


[SAP HANA Deployment Infrastructure Reference], Chapter 5: HDI with XS Advanced, Section 5.1: Developing with the SAP Web IDE for SAP HANA, Subsection 5.1.2: Configure Application Routing (xs-app.json), pp. 101-104.

[SAP HANA Platform Documentation], SAP HANA Developer Guide for SAP HANA XS Advanced Model, Chapter 4: Developing HTML5 Applications, Section 4.1: Developing HTML5 Applications Using SAP Web IDE for SAP HANA, Subsection 4.1.3: Configure Application Routing (xs-app.json), pp. 77-80.

Question 6

What types of user-defined functions are supported by SAP HANA? Note: There are 2 correct answers to this question.



Answer : A, B

SAP HANA supports two types of user-defined functions: table and scalar. User-defined functions are functions that are created by users to perform specific tasks or calculations on data. User-defined functions can be used in SQL expressions, such as in the SELECT, WHERE, or GROUP BY clauses of SQL statements. User-defined functions can also be used in SQLScript, which is a scripting language for SAP HANA that extends SQL with procedural and analytical features.

Table functions are user-defined functions that return a table as the output. Table functions can be used to implement complex logic or transformations on data, such as pivoting, unpivoting, aggregation, or ranking. Table functions can also be used to create calculation views, which are virtual data models that expose data from SAP HANA tables or views. Table functions are created by using the CREATE FUNCTION statement with the RETURNS <return_table_type> clause, where <return_table_type> specifies the table type of the output. Table functions can be called in the FROM clause of SQL statements, or in the node expression of calculation views.

Scalar functions are user-defined functions that return a scalar value as the output. Scalar functions can be used to perform simple calculations or validations on data, such as converting units, checking conditions, or generating IDs. Scalar functions are created by using the CREATE FUNCTION statement with the RETURNS <return_parameter_list> clause, where <return_parameter_list> specifies the scalar type of the output. Scalar functions can be called in the SELECT or WHERE clauses of SQL statements, or in the expression of calculated columns.

The following types of functions are not supported by SAP HANA as user-defined functions, but as built-in functions or features:

Aggregate functions: Aggregate functions are functions that perform calculations on a set of values and return a single value. For example, SUM, COUNT, MIN, MAX, or AVG are aggregate functions. Aggregate functions are built-in functions that are provided by SAP HANA and can be used in SQL expressions, such as in the SELECT or GROUP BY clauses of SQL statements, or in the expression of aggregated columns. Aggregate functions cannot be created by users as user-defined functions.

Hierarchy functions: Hierarchy functions are functions that operate on hierarchical data, such as parent-child or level-based hierarchies. For example, HIERARCHY_ANCESTORS, HIERARCHY_DESCENDANTS, or HIERARCHY_LEVEL are hierarchy functions. Hierarchy functions are built-in functions that are provided by SAP HANA and can be used in SQL expressions, such as in the SELECT or WHERE clauses of SQL statements, or in the expression of hierarchy columns. Hierarchy functions cannot be created by users as user-defined functions.


[SAP HANA Platform Documentation], SAP HANA SQL and System Views Reference, Chapter 3: SQL Expressions, Section 3.5: Function Expressions, pp. 59-60.

[SAP HANA Platform Documentation], SAP HANA SQLScript Reference, Chapter 6: SQLScript Test Framework, Section 6.1: User-Defined Functions, pp. 153-154.

Question 7

What do you reference in a role template? Please choose the correct answer.



Answer : D

A role template is a JSON file that defines the permissions and scopes for a specific role in a multi-target application. A scope is a string that represents a specific access right or privilege for a resource or service. For example, a scope can be used to grant read or write access to a database table or an OData service. A role template references the scopes that are required for the role to function properly. A role collection is a group of roles that can be assigned to a user or a group. A role is a collection of permissions and scopes that define what a user can do in an application. A route is a mapping between a URL path and a destination service in a multi-target application. A route is not related to a role template.Reference:

SAP HANA 2.0 SPS06 - Application Development for SAP HANA1, Section 6.1.1, p. 147-148

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.1, p. 25-26

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.2, p. 27-28

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.3, p. 29-30

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.4, p. 31-32

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.5, p. 33-34

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.6, p. 35-36

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.7, p. 37-38

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.8, p. 39-40

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.9, p. 41-42

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.10, p. 43-44

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.11, p. 45-46

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.12, p. 47-48

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.13, p. 49-50

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.14, p. 51-52

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.15, p. 53-54

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.16, p. 55-56

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.17, p. 57-58

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.18, p. 59-60

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.19, p. 61-62

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.20, p. 63-64

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.21, p. 65-66

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.22, p. 67-68

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.23, p. 69-70

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.24, p. 71-72

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.25, p. 73-74

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.26, p. 75-76

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.27, p. 77-78

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.28, p. 79-80

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.29, p. 81-82

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.30, p. 83-84

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.31, p. 85-86

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.32, p. 87-88

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.33, p. 89-90

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.34, p. 91-92

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.35, p. 93-94

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.36, p. 95-96

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.37, p. 97-98

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.38, p. 99-100

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.39, p. 101-102

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.40, p. 103-104

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.41, p. 105-106

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.42, p. 107-108

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.43, p. 109-110

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.44, p. 111-112

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.45, p. 113-114

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.46, p. 115-116

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.47, p. 117-118

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.48, p. 119-120

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.49, p. 121-122

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.50, p. 123-124

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.51, p. 125-126

SAP HANA 2.0 SPS06 - Cloud Foundry Environment2, Section 3.1.52, p. 127-128

SAP HANA 2.0 SPS06 - Cloud Foundry Environment


Page:    1 / 14   
Total 95 questions