]> begriffs open source - ai-pg/blob - full-docs/txt/features.txt
Convert HTML docs to more streamlined TXT
[ai-pg] / full-docs / txt / features.txt
1
2 Appendix D. SQL Conformance
3
4    Table of Contents
5
6    D.1. Supported Features
7    D.2. Unsupported Features
8    D.3. XML Limits and Conformance to SQL/XML
9
10         D.3.1. Queries Are Restricted to XPath 1.0
11         D.3.2. Incidental Limits of the Implementation
12
13    This section attempts to outline to what extent PostgreSQL conforms to
14    the current SQL standard. The following information is not a full
15    statement of conformance, but it presents the main topics in as much
16    detail as is both reasonable and useful for users.
17
18    The formal name of the SQL standard is ISO/IEC 9075 “Database Language
19    SQL”. A revised version of the standard is released from time to time;
20    the most recent update appearing in 2023. The 2023 version is referred
21    to as ISO/IEC 9075:2023, or simply as SQL:2023. The versions prior to
22    that were SQL:2016, SQL:2011, SQL:2008, SQL:2006, SQL:2003, SQL:1999,
23    and SQL-92. Each version replaces the previous one, so claims of
24    conformance to earlier versions have no official merit. PostgreSQL
25    development aims for conformance with the latest official version of
26    the standard where such conformance does not contradict traditional
27    features or common sense. Many of the features required by the SQL
28    standard are supported, though sometimes with slightly differing syntax
29    or function. Further moves towards conformance can be expected over
30    time.
31
32    SQL-92 defined three feature sets for conformance: Entry, Intermediate,
33    and Full. Most database management systems claiming SQL standard
34    conformance were conforming at only the Entry level, since the entire
35    set of features in the Intermediate and Full levels was either too
36    voluminous or in conflict with legacy behaviors.
37
38    Starting with SQL:1999, the SQL standard defines a large set of
39    individual features rather than the ineffectively broad three levels
40    found in SQL-92. A large subset of these features represents the “Core”
41    features, which every conforming SQL implementation must supply. The
42    rest of the features are purely optional.
43
44    The standard is split into a number of parts, each also known by a
45    shorthand name:
46      * ISO/IEC 9075-1 Framework (SQL/Framework)
47      * ISO/IEC 9075-2 Foundation (SQL/Foundation)
48      * ISO/IEC 9075-3 Call Level Interface (SQL/CLI)
49      * ISO/IEC 9075-4 Persistent Stored Modules (SQL/PSM)
50      * ISO/IEC 9075-9 Management of External Data (SQL/MED)
51      * ISO/IEC 9075-10 Object Language Bindings (SQL/OLB)
52      * ISO/IEC 9075-11 Information and Definition Schemas (SQL/Schemata)
53      * ISO/IEC 9075-13 Routines and Types using the Java Language
54        (SQL/JRT)
55      * ISO/IEC 9075-14 XML-related specifications (SQL/XML)
56      * ISO/IEC 9075-15 Multi-dimensional arrays (SQL/MDA)
57      * ISO/IEC 9075-16 Property Graph Queries (SQL/PGQ)
58
59    Note that some part numbers are not (or no longer) used.
60
61    The PostgreSQL core covers parts 1, 2, 9, 11, and 14. Part 3 is covered
62    by the ODBC driver, and part 13 is covered by the PL/Java plug-in, but
63    exact conformance is currently not being verified for these components.
64    There are currently no implementations of parts 4, 10, 15, and 16 for
65    PostgreSQL.
66
67    PostgreSQL supports most of the major features of SQL:2023. Out of 177
68    mandatory features required for full Core conformance, PostgreSQL
69    conforms to at least 170. In addition, there is a long list of
70    supported optional features. It might be worth noting that at the time
71    of writing, no current version of any database management system claims
72    full conformance to Core SQL:2023.
73
74    In the following two sections, we provide a list of those features that
75    PostgreSQL supports, followed by a list of the features defined in
76    SQL:2023 which are not yet supported in PostgreSQL. Both of these lists
77    are approximate: There might be minor details that are nonconforming
78    for a feature that is listed as supported, and large parts of an
79    unsupported feature might in fact be implemented. The main body of the
80    documentation always contains the most accurate information about what
81    does and does not work.
82
83 Note
84
85    Feature codes containing a hyphen are subfeatures. Therefore, if a
86    particular subfeature is not supported, the main feature is listed as
87    unsupported even if some other subfeatures are supported.