Oracle Package
Basically packages is set of procedures, functions, cursors, constraints and exceptions in one unit. To execute the package we write the code as follows: EXECUTE SALARY_PACKAGE.NEW_WORKER('MICE'); In above example SALARY_PACKAGE is package name and NEW_WORKER is procedure name. Creating Package To create package user should have the CREATE PROCEDURE privilege. Two create package two techniques have to be done separetly: (i) Creating package specification A package specification includes list of functions, procedures, variables, constraints, cursors nd exceptions and will be available for package body. CREATE OR REPLACE PACKAGE <NAME> ------- ------- Above code should be saved in saperate file with saperate name. (ii) Creating package body The name of package body should be equal to name of package specification but file name should be different than above file name. CREATE OR REPLACE PACKAGE BODY <NAME> -------