Part V. Server Programming

This part is about extending the server functionality with user-defined functions, data types, triggers, etc. These are advanced topics which should probably be approached only after all the other user documentation about LightDB has been understood. Later chapters in this part describe the server-side programming languages available in the LightDB distribution as well as general issues concerning server-side programming languages. It is essential to read at least the earlier sections of Chapter 35 (covering functions) before diving into the material about server-side programming languages.

Table of Contents

35. Extending SQL
35.1. How Extensibility Works
35.2. The LightDB Type System
35.3. User-Defined Functions
35.4. User-Defined Procedures
35.5. Query Language (SQL) Functions
35.6. Function Overloading
35.7. Function Volatility Categories
35.8. Procedural Language Functions
35.9. Internal Functions
35.10. C-Language Functions
35.11. Function Optimization Information
35.12. User-Defined Aggregates
35.13. User-Defined Types
35.14. User-Defined Operators
35.15. Operator Optimization Information
35.16. Interfacing Extensions to Indexes
35.17. Packaging Related Objects into an Extension
35.18. Extension Building Infrastructure
36. Triggers
36.1. Overview of Trigger Behavior
36.2. Visibility of Data Changes
36.3. Writing Trigger Functions in C
36.4. A Complete Trigger Example
37. Event Triggers
37.1. Overview of Event Trigger Behavior
37.2. Event Trigger Firing Matrix
37.3. Writing Event Trigger Functions in C
37.4. A Complete Event Trigger Example
37.5. A Table Rewrite Event Trigger Example
38. The Rule System
38.1. The Query Tree
38.2. Views and the Rule System
38.3. Materialized Views
38.4. Rules on INSERT, UPDATE, and DELETE
38.5. Rules and Privileges
38.6. Rules and Command Status
38.7. Rules Versus Triggers
39. Procedural Languages
39.1. Installing Procedural Languages
40. PL/pgSQLSQL Procedural Language
40.1. Overview
40.2. Structure of PL/pgSQL
40.3. Declarations
40.4. Expressions
40.5. Basic Statements
40.6. Control Structures
40.7. Cursors
40.8. Transaction Management
40.9. Errors and Messages
40.10. Trigger Functions
40.11. PL/pgSQL under the Hood
40.12. Tips for Developing in PL/pgSQL
40.13. Porting from Oracle PL/SQL
41. PL/oraSQLSQL Procedural Language
41.1. Overview
41.2. Structure of PL/oraSQL
41.3. Declarations
41.4. Data Types
41.5. Expressions
41.6. Basic Statements
41.7. Control Structures
41.8. Cursors
41.9. Collections
41.10. Transaction Management
41.11. Packages
41.12. Table function
41.13. Error Handling
41.14. Object name search rule
41.15. Enhancements for Oracle
42. Server Programming Interface
42.1. Interface Functions
42.2. Interface Support Functions
42.3. Memory Management
42.4. Transaction Management
42.5. Visibility of Data Changes
42.6. Examples
43. Background Worker Processes
44. Logical Decoding
44.1. Logical Decoding Examples
44.2. Logical Decoding Concepts
44.3. Streaming Replication Protocol Interface
44.4. Logical Decoding SQL Interface
44.5. System Catalogs Related to Logical Decoding
44.6. Logical Decoding Output Plugins
44.7. Logical Decoding Output Writers
44.8. Synchronous Replication Support for Logical Decoding
45. Replication Progress Tracking
English|中文