0

mainframe Online Quiz - 148

Description: mainframe Online Quiz - 148
Number of Questions: 20
Created by:
Tags: mainframe
Attempted 0/20 Correct 0 Score 0

Identify the mandatory info required to access uncatalogged dataset?

  1. space,dcb,unit,sol serial

  2. space,dcb,vol serial no

  3. Unit,vol serial no

  4. vol serial no


Correct Option: D

Which utility can be used to find volume serial info of a datset?

  1. IEBEGNER

  2. IEBGENER

  3. IDCAMS

  4. OPTION 1 AND 3


Correct Option: B

What is sqlcode -922 Error?

  1. Authorization faiure

  2. Load module not found

  3. Issu with Precompiller

  4. None


Correct Option: A

whats SDSF?

  1. Spool Display And Search Facility

  2. System Display And Search Facility

  3. option 1 AND 2

  4. option 1 or 2


Correct Option: C

Identify which one is more opt for DBRM?

  1. created by the DB2 precompiler and used in the bind process

  2. created by the cobol pre compiler and used in the bind process

  3. created by the cobol compiler and used in the bind process

  4. created by the DB2 compiler and used in the bind process


Correct Option: A

Identify which one is correct?

  1. Plan contains package and plan is executable

  2. Plan contains package and plan is not executable

  3. package contains only one dbrm as input and plan contains no of dbrms as input

  4. option 1 and 3


Correct Option: D

identify which one is correct?

  1. plan is obtained by binding DBRMs into packages

  2. plan is executable as it contains the acess path

  3. it is advantageous to use packages because it reduces the cost of bind

  4. All of the above


Correct Option: D

A REXX program (or REXX EXEC) called DEMO is stored in the partitioned dataset TBISUSR.REXXCRS.EXEC. Execution is possible...

  1. ... via the TSO command: EXEC 'TBISUSR.REXXCRS.EXEC(DEMO)' EXEC, without any

  2. ... only after allocation of the partitioned dataset TBISUSR.REXXCRS.EXEC to the DD

  3. ... via the TSO command: CALL 'TBISUSR.REXXCRS.EXEC(DEMO)', without any additional

  4. ... only after compilation to COBOL, and via the TSO command:


Correct Option: A

Indicate what is not correct in a REXX program.

  1. A REXX clause can be coded in uppercase, lowercase or mixed case.

  2. Multiple instructions can be coded on 1 line, as long as they are separated by a ','

  3. A REXX program should start with a comment clause /* REXX */

  4. Continuation of REXX instructions is achieved by using a ',' as a continuation indicator


Correct Option: B

AI Explanation

To answer this question, let's go through each option to understand why it is correct or incorrect:

Option A) A REXX clause can be coded in uppercase, lowercase, or mixed case. - This option is correct. In REXX, you can write code in uppercase, lowercase, or mixed case. The language is case-insensitive.

Option B) Multiple instructions can be coded on 1 line, as long as they are separated by a ',' - This option is incorrect. In REXX, multiple instructions cannot be coded on a single line by separating them with a ','. Each instruction should be written on a separate line.

Option C) A REXX program should start with a comment clause /* REXX / - This option is correct. It is a good practice to start a REXX program with a comment clause / REXX */ to indicate that it is a REXX program.

Option D) Continuation of REXX instructions is achieved by using a ',' as a continuation indicator - This option is correct. In REXX, you can use a ',' as a continuation indicator to continue a statement onto the next line.

The correct answer is B. Multiple instructions cannot be coded on 1 line, as long as they are separated by a ','. This statement is not correct in a REXX program.

Complete correctly: When defining a variable in REXX, one can use up to 250 characters to name the variable. The initial value will be...

  1. all blanks

  2. NULL value

  3. name of the variable in the same (mixed) case as the name.

  4. name of the variable in uppercase


Correct Option: D

AI Explanation

To answer this question, let's go through each option to understand why it is correct or incorrect:

Option A) all blanks - This option is incorrect because the initial value of a variable in REXX is not all blanks. The initial value will be determined by the assignment or the default value of the data type.

Option B) NULL value - This option is incorrect because REXX does not have a specific NULL value. The initial value of a variable will be determined by the assignment or the default value of the data type.

Option C) name of the variable in the same (mixed) case as the name - This option is incorrect because the initial value of a variable in REXX is not based on the variable name itself. The initial value will be determined by the assignment or the default value of the data type.

Option D) name of the variable in uppercase - This option is correct because when defining a variable in REXX, the initial value will be the name of the variable in uppercase. This means that the variable will initially have the same value as its name, but in uppercase.

The correct answer is D) name of the variable in uppercase. This option is correct because the initial value of a variable in REXX is the name of the variable in uppercase.

Consider the following: name = 'John' number1 = number2 number2 = 5 Which of the following REXX expressions will generate an error?

  1. 10 / number1

  2. name || 'number2'

  3. number2 * 3

  4. name > number2


Correct Option: A

AI Explanation

To determine which of the given REXX expressions will generate an error, let's go through each option:

A. 10 / number1 - This expression will generate an error because number1 has not been assigned a value. It is attempting to perform division with an undefined variable.

B. name || 'number2' - This expression will concatenate the value of the variable name with the string 'number2'. It will not generate an error.

C. number2 * 3 - This expression will multiply the value of the variable number2 by 3. It will not generate an error.

D. name > number2 - This expression will compare the value of the variable name with the value of the variable number2. It will not generate an error.

Therefore, the correct answer is A. This expression will generate an error because number1 has not been assigned a value.

Consider the following clauses: var_1 = 2 var_2 = 3 IF var_1 = var_2 THEN var_3 = var_1 var_4 = var_2 var_5 = var_2 + var_1 ELSE var_3 = var_2 var_4 = var_1 var_5 = var_2 - var_1 SAY "result = " var_3 var_4 var_5 What will happen when this REXX is executed:

  1. output on the terminal: result = 2 3 5

  2. output on the terminal: result = 3 2 1

  3. output on the terminal: result = var_3 var_4 var_5

  4. the program will terminate with an error


Correct Option: D

AI Explanation

To answer this question, let's go through each option to understand why it is correct or incorrect:

Option A) output on the terminal: result = 2 3 5 - This option is incorrect because the program will not reach this line of code. The correct answer indicates that the program will terminate with an error.

Option B) output on the terminal: result = 3 2 1 - This option is incorrect because the program will not reach this line of code. The correct answer indicates that the program will terminate with an error.

Option C) output on the terminal: result = var_3 var_4 var_5 - This option is incorrect because the program will not reach this line of code. The correct answer indicates that the program will terminate with an error.

Option D) the program will terminate with an error - This option is correct because the program encounters an error in the IF-THEN-ELSE statement. The condition "var_1 = var_2" evaluates to false, so the program executes the statements in the ELSE block. However, there is no statement to assign values to the variables var_3, var_4, and var_5 in the ELSE block. Therefore, the program will terminate with an error.

The correct answer is D. The program will terminate with an error.

Complete correctly: The EXIT clause ends...

  1. Ia loop unconditionally and continues with the next clause after the loop

  2. IF var_1 = var_2 THEN var_1 = var_1 + a loop and EXEC unconditionally, but doesn't return to the caller of the EXEC.

  3. a loop and EXEC unconditionally, returns to the caller of the EXEC and provides a return code.

  4. a loop and EXEC unconditionally, returns to the caller of the EXEC, but doesn't provide a return code.


Correct Option: C

Indicate the correct statement: REXX functions consist of a function name, immediately followed by its arguments coded between parentheses and separated by commas.

  1. This is only true if there are arguments, otherwise the parentheses must be excluded.

  2. This is also true if there are no arguments, but the parentheses can be omitted.

  3. This is also true if there are no arguments, the parentheses must be included.

  4. This is always true, since there are no functions without arguments.


Correct Option: C

Given that var_1 = 'Abc123', what is the result of DATATYPE(var_1,N)?

  1. '123'

  2. 'Abc123'

  3. 1

  4. 0


Correct Option: D

What is the result of TRUNC(12.3456,3)?

  1. 12.3

  2. 12.3000

  3. 12.346

  4. 12.345


Correct Option: D

AI Explanation

To answer this question, you need to understand the TRUNC function.

The TRUNC function is used to truncate a number to a specified number of decimal places. It removes all decimal places beyond the specified number without rounding the number.

In this case, the TRUNC(12.3456, 3) means truncating the number 12.3456 to 3 decimal places.

Let's evaluate each option:

Option A) 12.3 - This option is incorrect because it only has one decimal place, while the TRUNC function truncates the number to 3 decimal places.

Option B) 12.3000 - This option is incorrect because it has four decimal places, while the TRUNC function truncates the number to 3 decimal places.

Option C) 12.346 - This option is incorrect because it has three decimal places, while the TRUNC function truncates the number to 3 decimal places and removes the decimal places beyond that.

Option D) 12.345 - This option is correct because it has three decimal places, which matches the result of the TRUNC(12.3456, 3) function.

Therefore, the correct answer is D) 12.345.

Complete correctly: When calling a subroutine with the clause CALL 'SUBROUT1',...

  1. the external subroutine SUBROUT1 will be executed, bypassing any internal subroutines.

  2. the internal subroutine SUBROUT1 will be executed; external subroutines aren't called.

  3. the internal subroutines will be searched for SUBROUT1; only if there isn't an internal one, the external SUBROUT1 will be executed.

  4. an error will occur; subroutine names must never be coded between quotes.


Correct Option: A
- Hide questions