0

programming languages Online Quiz - 330

Description: programming languages Online Quiz - 330
Number of Questions: 20
Created by:
Tags: programming languages
Attempted 0/20 Correct 0 Score 0

It is possible to redirect the output of a process to more than one source

  1. True

  2. False


Correct Option: A

du command displays the file system usage for the entire file system

  1. True

  2. False


Correct Option: B

Shell functions are self-contained and cannot be accessed from outside the function

  1. True

  2. False


Correct Option: B

Under which two circumstances do you design database triggers? (Choose two)

  1. a) To duplicate the functionality of other triggers.

  2. b) To replicate built-in constraints in the Oracle server such as primary key and foreign key.

  3. c) To guarantee that when a specific operation is performed, related actions are performed.

  4. d) For centralized, global operations that should be fired for the triggering statement, regardless of which user or application issues the statement.


Correct Option: C,D
  1. a) A function must return a value.

  2. b) A procedure must return a value.

  3. c) A function executes a PL/SQL statement.

  4. d) A function is invoked as part of an expression.

  5. e) A procedure must have a return data type specify in its declaration.


Correct Option: A,D
  1. a) GRANT SELECT ON ADD_PLAYER TO PUBLIC;

  2. b) GRANT EXECUTE ON ADD_PLAYER TO PUBLIC;

  3. c) GRANT INSERT ON PLAYER TO PUBLIC;

  4. d) GRANT EXECUTE, INSERT ON ADD_PLAYER TO PUBLIC;

  5. e) REVOKE INSERT ON PLAYER FROM PUBLIC;


Correct Option: B,E

Which two statements about the overloading feature of packages are true? (Choose two)

  1. a) Only local or packaged sub programs can be overloaded.

  2. b) Overloading allows different functions with the same name that differ only in their return types.

  3. c) Overloading allows different subprograms with the same number, type and order of the parameter.

  4. d) Overloading allows different subprograms with the same name and same number or type of the parameters.

  5. e) Overloading allows different subprograms with the same name but different in either number or type or order of parameter.


Correct Option: A,E

Which two statements about packages are true?

  1. a) Packages can be nested.

  2. b) You can pass parameters to packages.

  3. c) A package is loaded into memory each time it is invoked.

  4. d) The contents of packages can be shared by many applications.

  5. e) You can achieve information hiding by making package constructs private.


Correct Option: D,E
  1. a) CREATE OR REPLACE FUNCTION tax_amt (p_id NUMBER) RETURN NUMBER

  2. b) CREATE OR REPLACE PROCEDURE tax_amt (p_id NUMBER) RETURN NUMBER

  3. c) CREATE OR REPLACE PROCEDURE tax_amt (p_id NUMBER, p_amount OUT NUMBER)

  4. d) CREATE OR REPLACE FUNCTION tax_amt (p_id NUMBER) RETURN NUMBER(10,2)

  5. e) CREATE OR REPLACE PROCEDURE tax_amt (p_id NUMBER, p_amount OUT NUMBER(10, 2))


Correct Option: A,C

Examine this procedure: CREATE OR REPLACE PROCEDURE UPD_BAT_STAT (V_ID IN NUMBER DEFAULT 10, V_AB IN NUMBER DEFAULT 4) IS BEGIN UPDATE PLAYER_BAT_STAT SET AT_BATS = AT_BATS + V_AB WHERE PLAYER_ID = V_ID; COMMIT; END; Which two statements will successfully invoke this procedure in SQL *Plus? (Choose two)

  1. a) EXECUTE UPD_BAT_STAT;

  2. b) EXECUTE UPD_BAT_STAT(V_AB=>10, V_ID=>31);

  3. c) EXECUTE UPD_BAT_STAT(31, 'FOUR', 'TWO');

  4. d) UPD_BAT_STAT(V_AB=>10, V_ID=>31);

  5. e) RUN UPD_BAT_STAT;


Correct Option: A,B

Which three are true regarding error propagation? (Choose three)

  1. a) An exception cannot propagate across remote procedure calls.

  2. b) An exception raised inside a declaration immediately propagates to the current block.

  3. c) The use of the RAISE; statement in an exception handler reprises the current exception

  4. d) An exception raised inside an exception handler immediately propagates to the enclosing block.


Correct Option: A,C,D

Which statements about JDBC are true? (2 answers)

  1. [_] [a] JDBC is an API to connect to relational-, object- and XML data sources

  2. [_] [b] JDBC stands for Java DataBase Connectivity

  3. [_] [c] JDBC is an API to access relational databases, spreadsheets and flat files

  4. [_] [d] JDBC is an API to bridge the object-relational mismatch between OO programs and relational


Correct Option: B,C

Which packages contain the JDBC classes?

  1. O (a) java.jdbc and javax.jdbc

  2. O (b) java.jdbc and java.jdbc.sql

  3. O (c) java.sql and javax.sql

  4. O (d) java.rdb and javax.rdb


Correct Option: C
  1. O (a) Type 1 driver

  2. O (b) Type 2 driver

  3. O (c) Type 3 driver

  4. O (d) Type 4 driver


Correct Option: A

Which type of driver converts JDBC calls into the network protocol used by the database management system directly?

  1. O (a) Type 1 driver

  2. O (b) Type 2 driver

  3. O (c) Type 3 driver

  4. O (d) Type 4 driver


Correct Option: D
- Hide questions