PL is a procedural language (Procedural Language) that extends SQL by adding programming language features to standard SQL statements. It organizes data operations and query statements within procedural code, enabling complex functionality through logical judgments, loops, and other operations.
Using PL allows developers to create programs with advanced features, encapsulate business logic within the database, and improve abstraction and security. It also reduces network interactions and speeds up calls, enhancing overall performance.
The main advantages of PL are as follows:
High performance
When interacting with the database using PL, all processing logic occurs on the database server, and only the required results are returned to the client. This significantly reduces data exchange between the application server and the database server, saving network resources and processing time.
PL objects are stored in the database in a precompiled form. Compared to standard SQL, the optimizer provides better optimization for PL, resulting in more efficient execution.
Easy development
Many features of PL help developers save time on development design and error troubleshooting. Developers can use OceanBase Developer Center (ODC) for efficient development.
For more information, see the ODC-related documentation on the OceanBase website.
Portability
For database developers, PL is a portable standard language. PL applications can run in any OceanBase database.
Easy management
PL objects are stored in the database. When making application modifications or version iterations, changing the database PL objects immediately affects all applications, eliminating concerns about differences in client code updates.