Supported Versions: Current (17) / 16 / 15 / 14 / 13
Development Versions: devel
Unsupported versions: 12 / 11 / 10 / 9.6 / 9.5 / 9.4 / 9.3 / 9.2 / 9.1 / 9.0 / 8.4 / 8.3 / 8.2 / 8.1 / 8.0 / 7.4
This documentation is for an unsupported version of PostgreSQL.
You may want to view the same page for the current version, or one of the other supported versions listed above instead.

VII. Internals

This part contains assorted information that can be of use to PostgreSQL developers.

Table of Contents
42. Overview of PostgreSQL Internals
42.1. The Path of a Query
42.2. How Connections are Established
42.3. The Parser Stage
42.4. The PostgreSQL Rule System
42.5. Planner/Optimizer
42.6. Executor
43. System Catalogs
43.1. Overview
43.2. pg_aggregate
43.3. pg_am
43.4. pg_amop
43.5. pg_amproc
43.6. pg_attrdef
43.7. pg_attribute
43.8. pg_cast
43.9. pg_class
43.10. pg_constraint
43.11. pg_conversion
43.12. pg_database
43.13. pg_depend
43.14. pg_description
43.15. pg_group
43.16. pg_index
43.17. pg_inherits
43.18. pg_language
43.19. pg_largeobject
43.20. pg_listener
43.21. pg_namespace
43.22. pg_opclass
43.23. pg_operator
43.24. pg_proc
43.25. pg_rewrite
43.26. pg_shadow
43.27. pg_statistic
43.28. pg_trigger
43.29. pg_type
43.30. System Views
43.31. pg_indexes
43.32. pg_locks
43.33. pg_rules
43.34. pg_settings
43.35. pg_stats
43.36. pg_tables
43.37. pg_user
43.38. pg_views
44. Frontend/Backend Protocol
44.1. Overview
44.2. Message Flow
44.3. Message Data Types
44.4. Message Formats
44.5. Error and Notice Message Fields
44.6. Summary of Changes since Protocol 2.0
45. PostgreSQL Coding Conventions
45.1. Formatting
45.2. Reporting Errors Within the Server
45.3. Error Message Style Guide
46. Native Language Support
46.1. For the Translator
46.2. For the Programmer
47. Writing A Procedural Language Handler
48. Genetic Query Optimizer
48.1. Query Handling as a Complex Optimization Problem
48.2. Genetic Algorithms
48.3. Genetic Query Optimization (GEQO) in PostgreSQL
48.4. Further Readings
49. Index Cost Estimation Functions
50. GiST Indexes
50.1. Introduction
50.2. Extensibility
50.3. Implementation
50.4. Limitations
50.5. Examples
51. Page Files
52. BKI Backend Interface
52.1. BKI File Format
52.2. BKI Commands
52.3. Example