Why do we need Package?

If I create N number of small procedures with one PL/SQL block (or) procedure why we need package?

Showing Answers 1 - 12 of 12 Answers

Bikramjit

  • Mar 19th, 2017
 

In package, we can have private procedure/function/record type variables which can hide the computation logic and original executable statements. But in a procedure, we cant create such private procedure/function/record type variables. Also, we keep similar procedure/functions in one place, so that that will help to easy navigation, maintenance and debug.
Hence, creating N number of procedure will create lot of issues during navigation, maintenance and debug.

  Was this answer useful?  Yes

Sumit Maheshwari

  • May 24th, 2017
 

The basic advantage is to secure code for unauthorised access.

  Was this answer useful?  Yes

Tarika Bhutani

  • May 25th, 2017
 

Whenever we run any subprogram of a package the whole package get loaded in SGA. Which actually reduces the number of context switching and hence increases speed and better performance. Whereas in procedures we the context switching is more. Procedures are useful for writing small modules.

  Was this answer useful?  Yes

Prasad Bagaregari

  • May 11th, 2018
 

An embedded object where all the required units can be in one place.

  Was this answer useful?  Yes

Give your answer:

If you think the above answer is not correct, Please select a reason and add your answer below.

 

Related Answered Questions

 

Related Open Questions