Intelligent Enterprises of the 21st Century

In this chapter, you will learn

  • The fundamental structure of an SQL procedure

  • The various clauses for the CREATE PROCEDURE statement

  • The structure of the procedure body

  • The statements that can be coded in the procedure body

Stored procedures are used to encapsulate multiple SQL statements with flow logic. They are database objects that serve as sub-routines to applications. SQL procedures are defined in a database using the CREATE PROCEDURE statement. This chapter introduces the syntax of the CREATE PROCEDURE statement and uses examples to illustrate how to create simple SQL procedures.

    Категории