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

Page: 1 / 14
Total 95 questions
Question 1

Which of the following are characteristics of database procedures?



Answer : A, B

According to the SAP HANA SQLScript Reference1, database procedures are subroutines that can be called from SQL statements or other database procedures. Database procedures can have the following characteristics:

Database procedures can have both input and output parameters; however, a parameter CANNOT be both input and output. Input parameters are used to pass values to the procedure, while output parameters are used to return values from the procedure. A parameter can be either scalar or table type, depending on the data type and cardinality. A parameter cannot be both input and output, because this would create ambiguity and inconsistency in the parameter passing mechanism. For example, you cannot declare a parameter as IN OUT, or assign a value to an input parameter, or read a value from an output parameter.For more information on database procedure parameters, see [Parameters of Database Procedures]2.

Database procedures can have several output parameters, and a mix of both scalar and table types is possible. Output parameters are used to return values from the procedure to the caller. A procedure can have zero or more output parameters, depending on the purpose and logic of the procedure. Output parameters can be either scalar or table type, depending on the data type and cardinality. A procedure can have a mix of both scalar and table output parameters, as long as they are compatible with the caller's expectations and syntax. For example, you can use a SELECT statement with INTO clause to assign values to scalar output parameters, or use a SELECT statement with RESULT clause to return a table output parameter.For more information on database procedure output parameters, see [Output Parameters of Database Procedures]3.

If, in the database procedure header, you use the READS SQL DATA option, then INSERT statements are prohibited; however, dynamic SQL is allowed. The READS SQL DATA option is used to indicate that the procedure only reads data from the database, and does not modify or write any data. This option is useful for performance optimization and security enforcement, as it allows the database to apply certain optimizations and checks to the procedure. However, this option also imposes some restrictions on the procedure, such as prohibiting any INSERT, UPDATE, DELETE, or MERGE statements, or any other statements that modify the database state. Dynamic SQL, which is SQL code that is constructed and executed at run time, is still allowed, as long as it does not violate the READS SQL DATA option.For more information on the READS SQL DATA option, see [Procedure Header Options]4.

If, in the database procedure header, you use the SQL SECURITY INVOKER option, then only the owner of the procedure can start it. The SQL SECURITY INVOKER option is used to indicate that the procedure is executed with the privileges of the user who invokes the procedure, rather than the privileges of the user who created the procedure. This option is useful for security enforcement and access control, as it allows the database to apply the appropriate authorization checks and restrictions to the procedure. However, this option does not affect who can start the procedure, as this is determined by the GRANT EXECUTE statement, which grants the execute privilege on the procedure to a specific user or role. The SQL SECURITY INVOKER option only affects how the procedure is executed, not who can execute it.For more information on the SQL SECURITY INVOKER option, see [Procedure Header Options]4.


Question 2

Which OData capacities are supported in SAP HANA extended application services, advanced model (XSA)? There are 3 correct answers to this question.



Answer : B, C, E

OData is a protocol for exposing and consuming data over the web using RESTful APIs. OData supports various capacities, such as query options, operations, and annotations, to enable flexible and powerful data access and manipulation. SAP HANA extended application services, advanced model (XSA) is a framework for developing and deploying cloud-native applications on SAP HANA. XSA supports OData v4 as one of the service types that can be defined and exposed by the SAP Cloud Application Programming Model (CAP). XSA supports the following OData capacities in CAP:

Aggregation: This capacity allows you to perform aggregation functions, such as sum, count, min, max, and average, on the data returned by an OData service. You can use the $apply query option to specify the aggregation expressions and groupings. XSA supports the OData Aggregation Extension for applying aggregations on entity sets and collections.

Join: This capacity allows you to perform join operations on the data returned by an OData service. You can use the $expand query option to include related entities or properties in the response. XSA supports the OData Association and Navigation concepts for defining and accessing the relationships between entities.

Association: This capacity allows you to define and use associations between entities in an OData service. Associations are semantic links that describe the cardinality and referential constraints of the relationships. You can use the OData Association and Referential Constraint annotations to specify the association details in the service definition or the metadata document.

The other options are not correct because:

A) Union: This capacity is not supported by OData or XSA. Union is a set operation that combines the results of two or more queries into a single result set. OData does not provide a query option or an extension for performing union operations on the data returned by an OData service.

D) Projection: This capacity is supported by OData, but not by XSA. Projection is a query option that allows you to select a subset of properties or entities from an OData service. You can use the $select query option to specify the properties or entities you want to include in the response. However, XSA does not support the $select query option in CAP, as it relies on the projection capabilities of the underlying data source, such as SAP HANA or PostgreSQL.


SAP Cloud Application Programming Model, OData v4 Support

SAP Cloud Application Programming Model, Annotations

OData Version 4.0 Part 1: Protocol

OData Version 4.0 Part 2: URL Conventions

OData Aggregation Extension for Data Services Version 4.0

Question 3

A Node.js module is executed for the first time in SAP HANA extended application services, advanced model (XS advanced). Which of the following activities are performed automatically? There are 2 correct answers to this question.



Answer : B, C

When a Node.js module is executed for the first time in SAP HANA extended application services, advanced model (XS advanced), the following activities are performed automatically12:

A new SAP HANA Deployment Infrastructure (HDI) container is created: An HDI container is a logical database schema that contains the database objects and data that are required by the Node.js module. An HDI container is created based on the configuration and definition files of the Node.js module, such as the package.json, the mta.yaml, and the hdi-config.json. The HDI container is bound to the Node.js module as a service, and it can be accessed using the HDI client library or the SQL client library.

The required modules are downloaded based on module dependencies: The Node.js module may depend on other modules or libraries that provide additional functionality or services, such as express, hdb, or passport. These dependencies are specified in the package.json file of the Node.js module, and they are downloaded and installed automatically from the npm registry or the SAP npm registry when the Node.js module is executed for the first time.

The other options are not correct because they are not activities that are performed automatically when a Node.js module is executed for the first time in XS advanced. The source code is not compiled to create an executable binary file, but rather interpreted and executed by the Node.js runtime environment. A new service is not executed on the application server, but rather the existing Node.js module is executed as a service on the application server.Reference:

SAP HANA Platform, Developing Applications with SAP HANA Cloud Platform, Developing Multi-Target Applications, Developing Node.js Modules

SAP HANA Platform, SAP HANA Extended Application Services, Advanced Model, Developing and Deploying Applications, Developing Node.js Applications


Question 4
Question 5

Which metadata declarations can you specify in a SQL Script procedure when you use the SAP HANA Deployment Infrastructure? There are 2 correct answers to this question.



Answer : B, C

You can specify the language and the default schema as metadata declarations in a SQL Script procedure when you use the SAP HANA Deployment Infrastructure (HDI). The language declaration defines the language mode of the procedure, which can be SQLSCRIPT or SQL. The default schema declaration defines the schema that is used to resolve unqualified object names in the procedure body. These declarations are optional and can be specified after the procedure name and before the parameter list. For example:

CREATE PROCEDURE MY_PROCEDURE LANGUAGE SQLSCRIPT DEFAULT SCHEMA MY_SCHEMA ( ... )

The other options are incorrect because security and authorization are not valid metadata declarations for SQL Script procedures. Security and authorization are handled by the HDI framework, which automatically grants the necessary privileges to the technical users and roles that access the HDI container objects. You do not need to specify any security or authorization clauses in the SQL Script procedure definition.Reference:

Procedure Metadata- SAP Help Portal

CREATE PROCEDURE Statement (Procedural)- SAP Help Portal

SAP HANA Deployment Infrastructure- SAP Help Portal

HA150 - SAP HANA 2.0 SPS06 SQLScript for SAP HANA- SAP Training


Question 6

You need to synchronize all unsynchronized changes of the remote Git branch with a local Git branch. Which operation do you use? Please choose the correct answer.



Answer : C

According to the SAP HANA Developer Guide, you use the pull operation to synchronize all unsynchronized changes of the remote Git branch with a local Git branch. The pull operation fetches the changes from the remote branch and merges them with the local branch. This way, you can update your local branch with the latest changes from the remote branch. The other options are incorrect, because:

Push is the opposite of pull. It sends the changes from the local branch to the remote branch, not the other way around.

Rebase is an alternative to merge. It rewrites the history of the local branch by applying the changes from the remote branch as new commits on top of the local branch. This creates a linear history, but it may cause conflicts or lose some information.

Reset is a way to undo changes in the local branch. It moves the branch pointer to a different commit, and optionally discards the changes in the working directory or the staging area.


Question 7

You need to initially load data from a .csv file into a Core Data Services table in SAP HANA extended application services, advanced model (XS advanced). Which file type do you create? Please choose the correct answer.



Answer : D

To initially load data from a .csv file into a Core Data Services (CDS) table in SAP HANA extended application services, advanced model (XS advanced), you need to create a file with extension .hdbti, which stands for HDB Table Import. This file defines the configuration and mapping for importing data from a local or remote file into a table in the HDI container. You can specify the source file name, location, format, delimiter, header, encoding, etc., as well as the target table name, schema, and column mapping. You can also specify whether to truncate the target table before importing, or to append the data to the existing table. You can use the SAP Web IDE for SAP HANA to create and deploy the .hdbti file, or use the HDI deployer CLI tool. The other options are incorrect because they are not the correct file types for importing data into a CDS table. A file with extension .hdbtabledata is a file that contains the data for a table in a JSON format, but it is not used for importing data from a .csv file. A file with extension .hdbtable is a file that defines the structure and properties of a table, but it does not contain any data. A file with extension .hdbdd is a file that defines the CDS entities, such as contexts, types, views, associations, etc., but it does not import any data.Reference:

Importing Data into Tables- SAP Help Portal

Creating Table Import Configuration Files- SAP Help Portal

HDI Deployer CLI Tool- SAP Help Portal

[HA300 - SAP HANA 2.0 SPS06 Modeling] - SAP Training


Page:    1 / 14   
Total 95 questions