Stored Procedures in Visual FoxPro


Procedural code called stored procedures are stored within a database container. Such procedures are loaded into memory when the database opens, improving performance. Because stored procedures are stored in the database, they assist in making your databases more portable. When the database is moved, the stored procedure goes with it. Use stored procedures to create user defined functions that you can call from other stored procedures, and from within validation rules at the field and record level.

You can create a stored procedure in three ways. The first way is click on Edit Stored procedures on the Database from within the Database Designer. The second way is to open the Project Manager and expand the nodes Data, Databases, Database, Stored Procedures, and then click on New. And the third way is to use the MODIFY PROCEDURE command.

Use the COPY PROCEDURES and APPEND PROCEDURES commands to copy and append stored procedures to a text file. For more information see PROCEDURE command.

Advertisements