C Abapd 2309

Download as pdf or txt
Download as pdf or txt
You are on page 1of 27

SAP

C_ABAPD_2309
SAP Certified Associate – Back-End Developer - ABAP Cloud
QUESTION & ANSWERS

https://www.dumpschief.com/C_ABAPD_2309-pdf-download.html
QUESTION: 1

A functional method must have

Option A :

Exactly one importing parameter

Option B :

No changing parameters

Option C :

Exactly one exporting parameter

Option D :

Exactly one returning parameter

Correct Answer: D

QUESTION: 2

Which of the following predefined ABAP types are complete? Note: There are 2 correct answers to this
question.

Option A :

Option B :

Option C :

https://www.dumpschief.com/C_ABAPD_2309-pdf-download.html
D

Option D :

Correct Answer: A,C

QUESTION: 3

When does SAP recommend to use a sorted or a hashed table respectively? (2 correct)

Option A :

A hashed table, when you read a subset in a loop and specify a part of the key from the left without gaps.

Option B :

A hashed table, when you read a single record and specify the complete key.

Option C :

A sorted table, when you read a subset in a loop and specify a part of the key from the left without gaps.

Option D :

A sorted table, when you read a single record and specify non-key fields.

Correct Answer: B,C

Explanation/Reference:

https://www.dumpschief.com/C_ABAPD_2309-pdf-download.html
QUESTION: 4

Which of the following signature elements may an instance constructor have? Note: There are 2 correct
answers to this question.

Option A :

Importing parameters

Option B :

Changing parameters

Option C :

Exceptions

Option D :

Exporting parameters

https://www.dumpschief.com/C_ABAPD_2309-pdf-download.html
Correct Answer: A,C

QUESTION: 5

Given the following Core Data Service View Entity Data Definition:

1 @AccessControl.authorizationCheck: #NOT_REQUIRED

2 DEFINE VIEW ENTITY demo_flight_info_join

3 AS SELECT

4 FROM scarr AS a

5 LEFT OUTER JOIN scounter AS c

6 LEFT OUTER JOIN sairport AS p

7 ON p.id = c.airport

8 ON a.carrid = c.carrid

9{

10 a.carrid AS carrier_id,

11 p.id AS airport_id,

12 c.countnum AS counter_number

13 }

In what order will the join statements be executed?

Option A :

sairport will be joined to scounter first and the result will be joined with scarr.

Option B :

scarr will be joined with sairport first and the result will be joined with scounter.

Option C :

scarr will be joined with scounter first and the result will be joined with sairport.

https://www.dumpschief.com/C_ABAPD_2309-pdf-download.html
Option D :

scounter will be joined to sairport first and the result will be joined with scarr.

Correct Answer: A

Explanation/Reference:

The order in which the join statements will be executed is:scarr will be joined with scounter first and the result will be joined

with sairport.This is because the join statements are nested from left to right, meaning that the leftmost data source is

joinedwith the next data source, and the result is joined with the next data source, and so on. The join condition foreach pair of

data sources is specified by the ON clause that follows the data source name. The join type foreach pair of data sources is

specified by the join operator that precedes the data source name. In this case, thejoin operator is LEFT OUTER JOIN, which

means that all the rows from the left data source are included inthe result, and only the matching rows from the right data

source are included.If there is no matchingrow fromthe right data source, the corresponding fields are filled with initial

values1.Therefore, the join statements will be executed as follows:First, scarr AS a will be joined with scounter AS c using the

join condition a.carrid = c.carrid. Thismeans that all the rows from scarr will be included in the result, and only the rows from

scounter thathave the same value for the carrid field will be included. If there is no matching row from scounter, thecountnum

field will be filled with an initial value.Second, the result of the first join will be joined with sairport AS p using the join condition

p.id =c.airport. This means that all the rows from the first join will be included in the result, and only the rowsfrom sairport that

have the same value for the id field as the airport field from the first join will beincluded. If there is no matching row from

sairport, the id field will be filled with an initial value.References:1: Join - ABAP Keyword Documentation

QUESTION: 6

Which of the following uses of SQL function SUBSTRING( ) returns the same result as LEFT( text_field, 1)?

Option A :

SUBSTRING(text_field, 1, 1 )

Option B :

SUBSTRING(text_field, 1, 0 )

Option C :

https://www.dumpschief.com/C_ABAPD_2309-pdf-download.html
SUBSTRING(text_field, 0, 1 )

Correct Answer: A

Explanation/Reference:

LEFT( text_field, 1 ) and SUBSTRING( text_field, 1, 1 ) return the same result.

QUESTION: 7

Which of the following method calls in a RAP validation create messages which are translatable? Note: There
are 2 correct answers to this question.

Option A :

DATA(msg) = me->new_message_with_text( severity = ms-error text = |Airport does not exist| ).

Option B :

DATA(msg) = me->new_message_with_text( severity = ms-error text = |{ 'Airport does not exist'(ane) } |


).

Option C :

DATA(msg) = me->new_message_with_text( severity = ms-error text = 'Airport does not exist ' ).

Option D :

DATA(msg) = me->new_message_with_text( severity = ms-error text = 'Airport does not exist'(ane) ).

Correct Answer: B,D

https://www.dumpschief.com/C_ABAPD_2309-pdf-download.html
Explanation/Reference:

Only those method calls that reference a text symbol by using (ane) after the text literal create a translatable message.

QUESTION: 8

You subtract one field with type D from another field with type D. What is the data type of the result?

Option A :

Option B :

Option C :

UTCLONG

Option D :

Correct Answer: A

Explanation/Reference:

The result of adding or subtracting date fields is an integer.

QUESTION: 9

In our scenario, what is coded in a behavior implementation? Note: There are 2 correct answers to this

https://www.dumpschief.com/C_ABAPD_2309-pdf-download.html
question.

Option A :

Update

Option B :

Determinations

Option C :

Validations

Correct Answer: B,C

Explanation/Reference:

Validations and determinations are coded in the behavior implementation. But In the managed implementation scenario, the

RAP framework takes care of the standard operations create, update and delete.

QUESTION: 10

Which of the following can you use to copy data from one internal table to another? Note: There are 2 correct
answers to this question.

Option A :

The UPDATEstatement

Option B :

The SELECT statement.

Option C :

https://www.dumpschief.com/C_ABAPD_2309-pdf-download.html
The CORRESPONDING #( )operator

Option D :

A table comprehension with VALUE #( )

Correct Answer: C,D

QUESTION: 11

EXTRACT_MONTH( ) is a generic SQL function which can handle input of different types. Which of the
following built-in types are allowed for this function? Note: There are 3 correct answers to this question.

Option A :

DATS

Option B :

UTCLONG

Option C :

DATN

Option D :

TIMESTAMPL

Option E :

TIMS

Correct Answer: A,B,C

https://www.dumpschief.com/C_ABAPD_2309-pdf-download.html
Explanation/Reference:

Like all other generic SQL functions EXTRACT_MONTH supports only timestamps of type UTCLONG. It does not support

TIMESTAMP and TIMESTAMPL. But it supports both date types, DATN and DATS. Time fields are not a valid input for this specific

function because you cannot extract a month from a point in time.

QUESTION: 12

Where do you create translatable texts for your exception classes?

Option A :

As a message in a message class

Option B :

As a text element in the text pool of the class

Option C :

As a constant in the class definition

Correct Answer: A

Explanation/Reference:

You create texts for exception classes as a message in a message class.

QUESTION: 13

You change the definition of a database table. In which of the following scenarios do you have to manually
adjust the database table?

https://www.dumpschief.com/C_ABAPD_2309-pdf-download.html
Option A :

The database table is empty and you added a table field

Option B :

The database table is empty and you deleted a table field.

Option C :

The database table contains data and you deleted a table field.

Option D :

The data base table contains data and you added a table field.

Correct Answer: C

Explanation/Reference:

When the table is empty, it is deleted and created again. A new table field is added with the ALTER TABLE statement.

QUESTION: 14

You define a database table in the ABAP Dictionary. What is needed to make the database table client
dependent?

Option A :

A corresponding setting in the Technical Table Properties.

Option B :

Annotation @ABAPCatalog.clientDependent: true

https://www.dumpschief.com/C_ABAPD_2309-pdf-download.html
Option C :

A key field of type CLNT

Correct Answer: C

Explanation/Reference:

A database table is client dependent if it has a key field of type CLNT.

QUESTION: 15

Which of the following are key parts of the clean core concept? Note: There are 3 correct answers to this
question.

Option A :

Elimination of modifications

Option B :

Deletion old versions

Option C :

Usage of released APIs

Option D :

Copying (that is, cloning) of standard code in lieu of modifications

Option E :

Strict separation between extensions and the underlying application

https://www.dumpschief.com/C_ABAPD_2309-pdf-download.html
Correct Answer: A,C,E

QUESTION: 16

You have written a program that uses inline declarations and assigns values using expressions. The global
data declarations contain the following statement: DATA o TYPE REF TO cl_class. Which of the following are
valid statements? Note: There are 3 correct answers to this question.

Option A :

o = NEW cl_class( ).

Option B :

DATA(p) = NEW( ).

Option C :

o = NEW( ).

Option D :

o = NEW string( ).

Option E :

DATA(p) = NEW cl_class( ).

Correct Answer: A,C,E

QUESTION: 17

Given this code,

1. DATA: go_super TYPE REF TO lcl_super,

https://www.dumpschief.com/C_ABAPD_2309-pdf-download.html
2. go_sub1 TYPE REF TO lcl_sub1,

3. go_sub2 TYPE REF TO lcl_sub2.

4.

5. go_super = NEW go_sub2(...).

6. go_super = NEW go_sub1(...).

7. go_sub1 = CAST #( go_super ).

8. go_sub1->sub1_meth1(...).

9. go_sub2 = CAST #( go_super).

10. go_sub2->sub2_meth1(...).

With Icl_super being superclass for Icl_sub1 and Icl_sub2 and with methods sub1_meth1 and sub2_meth1
being subclass-specific methods of Ic_sub1 or Icl_sub2, respectively.

What will happen when executing these casts? (2 correct)

Option A :

go_sub1->sub1_meth 1(…). will work.

Option B :

go_sub1 = CAST #( go_super ), will not work

go_sub2 = CAST #( go_super ), will work.

Option C :

go_sub2->sub2_meth 1(...). will work

Option D :

go_sub1 = CAST #( go_super ), will work

go_sub2 = CAST #( go_super ). will not work.

Correct Answer: A,D

https://www.dumpschief.com/C_ABAPD_2309-pdf-download.html
Explanation/Reference:

CastingIn the case of casting, we are actually only talking about the assignment of an instance to a reference that does not

have the same type as the instance, but the two objects are known to one another through an interface or via inheritance. Let's

take the following class model, which we have already used in this article:

To do this, we now create a reference


variable that refers to the superclass LCL_VEHICLE. In the first example we create a new instance of the object and can call the

SPEED_UP method directly.1. DATA:2. go_vehicle TYPE REF TO lcl_vehicle.3. 4. go_vehicle = NEW #( ).5. go_vehicle-

>speed_up( ).

In the next step we create a new instance of the type LCL_CAR, i.e. a special variant of LCL_VEHICLE, and assign the object to

our reference. The assignment works because the variable is of an equivalent or more general derivation of the class.1.

go_vehicle = NEW lcl_car( ).2. go_vehicle->speed_up( ).

However, we do not get to the special method of the class LCL_CAR via the reference variable, since the variable refers to

LCL_VEHICLE and thus only knows the SPEED_UP method. At this point we have to do a CAST first.1. DATA(go_casted_car) =

CAST lcl_car( go_vehicle ).2. go_casted_car->open_luggage_space( ).

After the CAST we have a new reference variable of the type LCL_CAR via which we can then call the corresponding method

and thus also use the functions of LCL_CAR. This is also possible with a chaining.1. CAST lcl_car( go_vehicle )-

>open_luggage_space( ).

Let's take the example from the beginning again and try to cast our reference of the type LCL_VEHICLE to the class LCL_CAR. In

this case we will get an exception because the more general instance cannot be cast on a more specific instance. The more

specific instance has more specific characteristics and more attributes that may not yet have been initialized.1. TRY.2.

DATA(go_casted_vehicle) = CAST lcl_car( go_vehicle ).3. go_casted_vehicle->open_luggage_space( ).4. 5. CATCH

cx_sy_move_cast_error.6. ENDTRY.

The complete example from this chapter therefore looks like this:1. DATA:2. go_vehicle TYPE REF TO lcl_vehicle.3. 4.

go_vehicle = NEW #( ).5. go_vehicle->speed_up( ).6. 7. TRY.8. DATA(go_casted_vehicle) = CAST lcl_car( go_vehicle ).9.

go_casted_vehicle->open_luggage_space( ).10. 11. CATCH cx_sy_move_cast_error.12. ENDTRY13. 14. go_vehicle = NEW

lcl_car( ).15. go_vehicle->speed_up( ).16. 17. DATA(go_casted_car) = CAST lcl_car( go_vehicle ).18. go_casted_car-

>open_luggage_space( ).19. 20. CAST lcl_car( go_vehicle )->open_luggage_space( ).ConclusionWorking with objects and

https://www.dumpschief.com/C_ABAPD_2309-pdf-download.html
instances can be a bit confusing at first, but it follows a very precise logic. With inheritance, you can easily reuse source code,

but you have to pay attention to the specialties when accessing it.

QUESTION: 18

You want to use the extensibility app, Custom Fields and Logic, to define custom fields for an SAP Fiori app.
Which of the following conditions is a prerequisite for this activity?

Option A :

You must release the SAP Fiori app for extensibility using the Enable Fields for Use transaction in the
Custom Fields and Logic (SCFD_EUI) app.

Option B :

There is no specific requirement. Custom fields can basically be created for any SAP Fiori app.

Option C :

Custom fields can only be created for SAP Fiori apps that have been enabled by SAP for this type of
extension.

Option D :

You must release the SAP Fiori app for extensibility via Transaction Setup Adaptation Transport Organizer
for Key User Tools (S_ATO_SETUP).

Correct Answer: C

QUESTION: 19

The Entity Manipulation Language (EML) is an extension of which of the following?

Option A :

The ABAP Programming Language

https://www.dumpschief.com/C_ABAPD_2309-pdf-download.html
Option B :

The Structured Query Language

Option C :

The Behavior Definition Language

Option D :

The Service Definition Language

Correct Answer: A

QUESTION: 20

You want to define an ABAP Core Data Services (CDS) view that totals the NET_AMOUNT column for each
sales order (column SOJD). Which SELECT statement would you use in the definition? Please choose the
correct answer.

Option A :

select from snwd_so {sojd, sum(net_amount) as sum_amount}

Option B :

select from snwd_so {so_id( sum(net_amount) as sum_amount} group by sojd

Option C :

select from snwd_so {so_id( sum(net_amount) as sum_amount} group by net_amount

Option D :

select from snwd_so {so_id( sum(net_amount) as sum_amount} order by sojd

https://www.dumpschief.com/C_ABAPD_2309-pdf-download.html
Correct Answer: B

QUESTION: 21

What is the purpose of a foreign key relationship between two tables in the ABAP Dictionary?

Option A :

To create a corresponding foreign key relationship in the database

Option B :

To ensure the integrity of data in the corresponding database tables

Option C :

To document the relationship between the two tables

Correct Answer: C

Explanation/Reference:

https://www.dumpschief.com/C_ABAPD_2309-pdf-download.html
QUESTION: 22

When processing a loop with the statement DO... ENDDO, what system variable contains the implicit loop
counter?

Option A :

sy-linno

Option B :

sy-tabix

Option C :

sy-subrc

Option D :

sy-index

https://www.dumpschief.com/C_ABAPD_2309-pdf-download.html
Correct Answer: D

Explanation/Reference:

When processing a loop with the statement DO… ENDDO, the system variable that contains the implicit loop counter is sy-

index. The loop counter is a numeric value that indicates how many times the loop has been executed. The loop counter is

initialized to 1 before the first execution of the loop and is incremented by 1 after each execution. The loop counter can be

used to control the number of loop iterations or to access the loop elements by index. The loop counter can also be accessed or

modified within the loop body, but this is not recommended as it may cause unexpected results or errors1.For example, the

following code snippet uses the loop counter sy-index to display the numbers from 1 to 10:

DO 10 TIMES. WRITE: / sy-index. ENDDO.

The output of this code is:

1 2 3 4 5 6 7 8 9 10

References: 1: DO - ABAP Keyword Documentation

QUESTION: 23

Given the following code in an SAP S/4HANA Cloud private edition tenant:

CLASS zcl_demo_class DEFINITION.

METHODS: m1.

ENDCLASS.

CLASS zcl_demo_class IMPLEMENTATION.

METHOD m1.

CALL FUNCTION 'ZF1'.

ENDMETHOD.

ENDCLASS.

The class zcl_demo_class is in a software component with the language version set to "ABAP Cloud". The
function module ZF1' is in a different software component with the language version set to "Standard ABAP".
Both the class and function module are customer created. Regarding line #6, which of the following are valid
statements?

Option A :

https://www.dumpschief.com/C_ABAPD_2309-pdf-download.html
ZF1' can be called only if it is released for cloud development.

Option B :

'ZF1' can be called if a wrapper is created for it and the wrapper itself is released for cloud development.

Option C :

"ZF1" can be called whether it is released or not for cloud development

Option D :

ZF1" can be called if a wrapper is created for it but the wrapper itself is not released for cloud
development

Correct Answer: A,B

Explanation/Reference:

The ABAP Cloud Development Model requires that only public SAP APIs and extension points are used toaccess SAP

functionality and data. These APIs and extension points are released by SAP and documented inthe SAP API BusinessHub1.

Customer-created function modules are not part of the public SAP APIs and arenot released for cloud development. Therefore,

calling a function module directly from an ABAP Cloud classis not allowed and will result in a syntax error. However, there are

two possible ways to call a function moduleindirectly from an ABAP Cloud class:Create a wrapper class or interface for the

function module and release it for cloud development. Awrapper is a class or interface that encapsulates the function module

and exposes its functionalitythrough public methods or attributes. The wrapper must be created in a software component with

thelanguage version set to “Standard ABAP” and must be marked as released for cloud development usingthe annotation

@EndUserText.label. The wrapper can then be called from an ABAP Cloud class usingthe public methods or attributes2.Use the

ABAP Cloud Connector to call the function module as a remote function call (RFC) from anABAP Cloud class. The ABAP Cloud

Connector is a service that enables the secure and reliablecommunication between SAP BTP, ABAP environment and on-

premise systems. The function modulemust be exposed as an RFC-enabled function module in the on-premise system and

must be registered inthe ABAP Cloud Connector. The ABAP Cloud class can then use the class cl_rfc_destination_service toget

the destination name and the class cl_abap_system to create a proxy object for the functionmodule. The proxy object can then

be used to call the function module3.References: 1: SAP API Business Hub 2: Creating an ABAP Cloud Project | SAP Help Portal

3: CallingRemote Function Modules | SAP Help Portal

https://www.dumpschief.com/C_ABAPD_2309-pdf-download.html
QUESTION: 24

Which of the following are parts of the definition of a new database table? (2 correct)

Option A :

Extension

Option B :

Semantic table attributes

Option C :

Partitioning attributes

Option D :

Field list

Correct Answer: B,D

QUESTION: 25

In an Access Control Object, which clauses are used? (3 correct)

Option A :

Grant (to identify the data source)

Option B :

Where (to specify the access conditions)

Option C :

https://www.dumpschief.com/C_ABAPD_2309-pdf-download.html
Define role (to specify the role name)

Option D :

Revoke (to remove access to the data source)

Option E :

Return code (to assign the return code of the authority check)

Correct Answer: A,B,C

Explanation/Reference:

An Access Control Object (ACO) is a CDS annotation that defines the access control rules for a CDS view entity. An ACO consists

of one or more clauses that specify the role name, the data source, the access conditions, and the return code of the authority

check12. Some of the clauses that are used in an ACO are:

Where (to specify the access conditions): This clause is used to define the logical expression that

determines whether a user has access to the data source or not. The expression can use the fields of the

data source, the parameters of the CDS view entity, or the predefined variables $user and $session. The

expression can also use the functions check_authorization and check_role to perform additional

authority checks12.

Define role (to specify the role name): This clause is used to assign a name to the role that is defined by

the ACO. The role name must be unique within the namespace of the CDS view entity and must not

contain any special characters. The role name can be used to reference the ACO in other annotations,

such as @AccessControl.authorizationCheck or @AccessControl.grant12.

Revoke (to remove access to the data source): This clause is used to explicitly deny access to the data

source for a user who meets the conditions of the where clause. The revoke clause overrides any grant

clause that might grant access to the same user. The revoke clause can be used to implement the

principle of least privilege or to enforce data segregation12.

https://www.dumpschief.com/C_ABAPD_2309-pdf-download.html
You cannot do any of the following:

Grant (to identify the data source): This is not a valid clause in an ACO. The grant clause is a separate

annotation that is used to grant access to a CDS view entity or a data source for a user who has a specific

role. The grantclause can reference an ACO by its role name to apply the access conditions defined by

the ACO12.

Return code (to assign the return code of the authority check): This is not a valid clause in an ACO. The

return code of the authority check is a predefined variable that is set by the system after performing the

access control check. The return code can be used in the where clause of the ACO to specify different

access conditions based on the outcome of the check12.

References: 1: Access Control Objects - ABAP Keyword Documentation - SAP Online Help 2: Access

Control in Core Data Services (CDS) | SAP Help Portal

QUESTION: 26

The SQL statement used to read data from a database table is which of the following?

Option A :

READ

Option B :

SELECT

Option C :

GET

Option D :

FIND

https://www.dumpschief.com/C_ABAPD_2309-pdf-download.html
Correct Answer: B

Explanation/Reference:

Which extensibility type does SAP recommend you to enhance the existing Ul for an SAP Fiori app?

QUESTION: 27

Match the sequence of execution in the dropdown list to the operation. (1 is the highest priority and 3 is the
lowest priority.)

Option A :

1,2,3

Option B :

1,3,2

Option C :

2,1,3

Option D :

3,1,2

Option E :

2,3,1

https://www.dumpschief.com/C_ABAPD_2309-pdf-download.html
Correct Answer: D

Explanation/Reference:

https://help.sap.com/doc/abapdocu_cp_index_htm/CLOUD/en-US/abenarith_operators.htm

https://www.dumpschief.com/C_ABAPD_2309-pdf-download.html

You might also like