1Z0-144 · Question #79
Which two statements are true about anonymous blocks and named subprograms? (Choose two)
The correct answer is A. Subprograms are by default executed with definer's rights. B. The declare section is optional for both anonymous blocks and subprograms. By default, stored procedures and SQL methods execute with the privileges of their owner, not their current user. Such definer's rights subprograms are bound to the schema in which they reside, allowing you to refer to objects in the same schema without qualifying their names.
Question
Which two statements are true about anonymous blocks and named subprograms? (Choose two)
Options
- ASubprograms are by default executed with definer's rights.
- BThe declare section is optional for both anonymous blocks and subprograms.
- CBoth anonymous blocks and subprograms execute by default with invoker's rights.
- DThe declare section is mandatory for anonymous blocks and optional for subprograms.
How the community answered
(25 responses)- A76% (19)
- C16% (4)
- D8% (2)
Explanation
By default, stored procedures and SQL methods execute with the privileges of their owner, not their current user. Such definer's rights subprograms are bound to the schema in which they reside, allowing you to refer to objects in the same schema without qualifying their names.
Topics
Community Discussion
No community discussion yet for this question.