Compiling Specification Part and Body Part

If have 5 procedures in my specification part and used 4 in my body part while compiling will it throw error or not?

Showing Answers 1 - 10 of 10 Answers

vishal pathak

  • Mar 24th, 2017

No, It wont go through compilation error.. but if it is vice versa, then will through error, saying "Package body not defined/declared in specification" something like this...

  Was this answer useful?  Yes


  • Apr 11th, 2017

It is compulsory to define all procedures, function in packages body as well if we are declaring it in package specification section.

  Was this answer useful?  Yes

Tarika Bhutani

  • May 25th, 2017

Yes, We can have 5 procedures in specification and define only 4 in package body. The advantage of this we can later on add the definition whenever required.

  Was this answer useful?  Yes

vishal pathak

  • Jun 7th, 2017

Yes, If procedure declared in specification not defined in body will through compilation error saying:- "procedure declared in package specification must defined in body". but vice-versa will not throw any error

  Was this answer useful?  Yes

Shridevi Bhat

  • Jun 30th, 2017

Yes it will throw error. all the declared procedures and functions must be there in package body with implementation.
Error(15,22): PLS-00323: subprogram or cursor GET_REPORT_URL1 is declared in a package specification and must be defined in the package body

  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