Understanding stored procedure

xiaoxiao2021-03-06  23

The Reason To Use Stored Procedure: Simplicity, Security, Performance

1. To Simplify Complex Operations by Encapsulating Processes Into A Single Easy-To-Use Unit

2. TO Ensure Data Consistency by NOT Requiring That A Series of Steps Be Treated over and over. If all develd procedure, The Same Code Will Be buy by all all

3. TO Prevent Errors. The More Steins That Need To Be Performed, The More Likely It is That Errors Will BE Introduces Data Consistency.

4. To simplify change management. If tables, column names, or business logic (or just about anything) changes, then only the stored procedure code needs to be updated, and no one else will need even to be aware that changes were made.

5. To Enhance Security. Restricting Access To Underlying Data Via Stores Procedures Reduces The Chance Other Werwise

6. Because Stored Procedures Are Usually Stored In A Compiled Form, The Database System Has To Do Less Work to Process The Command. This Results In Immand.

The Downside of Using Stored Procedure:

1. Stored Procedures Syntax Varies Between Different DBMS

2. Stored procedures tend to be more complex to write than basic SQL statements, and writing them requires a greater degree of skill and experience. As a result, many database administrators restrict stored procedure creation rights as a security measure.

转载请注明原文地址:https://www.9cbs.com/read-43336.html

New Post(0)