IBM DB2 11.1 Advanced DBA for Linux, UNIX, and Windows — Question 33
Which of the following statements about stored procedures is TRUE?
Answer options
- A. Stored procedures can be written in SQL PL, but not in the PL/SQL dialect
- B. The CREATE SOURCED PROCEDURE statement defines a procedure that is based on another procedure in a federated database
- C. There are three types of stored procedures which can be deployed: SQL procedures, external procedures, and sourced procedures
- D. Two identically-named procedures within a schema are permitted to have exactly the same number of parameters, but the parameters must have different data types assigned
Correct answer: B
Explanation
Option B is correct because the CREATE SOURCED PROCEDURE statement indeed defines a procedure that is based on another procedure in a federated database. Option A is incorrect as stored procedures can be written in both SQL PL and PL/SQL. Option C incorrectly states the number of types, while Option D is wrong because procedures with the same name cannot have the same parameter count, regardless of data types.