ISO/IEC 9075-14:2023
(Main)Information technology — Database languages SQL — Part 14: XML-Related Specifications (SQL/XML)
Information technology — Database languages SQL — Part 14: XML-Related Specifications (SQL/XML)
Technologies de l'information — Langages de base de données SQL — Partie 14: Spécifications relatives au XML (SQL/XML)
General Information
Relations
Standards Content (Sample)
INTERNATIONAL ISO/IEC
STANDARD 9075-14
Sixth edition
2023-06
Information technology — Database
languages SQL —
Part 14:
XML-Related Specifications (SQL/
XML)
Technologies de l'information — Langages de base de données SQL —
Partie 14: Spécifications relatives au XML (SQL/XML)
Reference number
ISO/IEC 9075-14:2023(E)
© ISO/IEC 2023
---------------------- Page: 1 ----------------------
ISO/IEC 9075-14:2023(E)
COPYRIGHT PROTECTED DOCUMENT
© ISO/IEC 2023
All rights reserved. Unless otherwise specified, or required in the context of its implementation, no part of this publication may
be reproduced or utilized otherwise in any form or by any means, electronic or mechanical, including photocopying, or posting on
the internet or an intranet, without prior written permission. Permission can be requested from either ISO at the address below
or ISO’s member body in the country of the requester.
ISO copyright office
CP 401 • Ch. de Blandonnet 8
CH-1214 Vernier, Geneva
Phone: +41 22 749 01 11
Email: copyright@iso.org
Website: www.iso.org
Published in Switzerland
ii
© ISO/IEC 2023 – All rights reserved
---------------------- Page: 2 ----------------------
ISO/IEC9075-14:2023(E)
Contents Page
Foreword.ix
Introduction.xi
1 Scope.1
2 Normativereferences.2
3 Termsanddefinitions.4
4 Concepts.14
4.1 Notationsandconventions.14
4.1.1 Notations.14
4.1.2 XML-related notations.14
4.2 Data types.15
4.2.1 Namingofpredefinedtypes.15
4.2.2 Datatypeterminology.16
4.3 XML.16
4.3.1 Introduction.16
4.3.2 XML types.16
4.3.3 CharacteristicsofXMLvalues.17
4.3.4 XMLcomparisonandassignment.18
4.3.5 OperationsinvolvingXMLvalues.18
4.3.6 RegisteredXMLschemas.20
4.4 Dataconversions.21
4.5 Dataanalysisoperations.22
4.5.1 Aggregate functions.22
4.6 SQL-invokedroutines.22
4.6.1 Routine descriptors.22
4.7 SQL-statements.23
4.7.1 SQL-statementsclassifiedbyfunction.23
4.7.1.1 SQL-sessionstatements.23
4.8 Basicsecuritymodel.23
4.8.1 Privileges.23
4.9 SQL-sessions.23
4.9.1 SQL-sessionproperties.23
4.10 XMLnamespaces.24
4.11 Overviewofmappings.24
4.11.1 Introductiontomappings.24
4.11.2 MappingSQLcharactersetstoUnicode.25
4.11.3 MappingUnicodetoSQLcharactersets.25
4.11.4 MappingSQLstoXML.25
4.11.5 MappingXMLnamestoSQL.25
©ISO/IEC2023–Allrightsreserved iii
---------------------- Page: 3 ----------------------
ISO/IEC9075-14:2023(E)
4.11.6 MappingSQLdatatypestoXML.26
4.11.7 MappingvaluesofSQLdatatypestoXML.27
4.11.8 MappingXQueryatomicvaluestoSQLvalues.28
4.11.9 Visibilityofcolumns,tables,andschemasinmappingsfromSQLtoXML.29
4.11.10 MappinganSQLtabletoXML.29
4.11.11 MappinganSQLschematoXML.30
4.11.12 MappinganSQLcatalogtoXML.30
5 Lexicalelements.32
5.1 and.32
5.2 .34
5.3 Namesandidentifiers.35
6 Scalarexpressions.36
6.1 .36
6.2 .39
6.3 .40
6.4 and.41
6.5 .42
6.6 .43
6.7 .46
6.8 .54
6.9 .55
6.10 .60
6.11 .61
6.12 .62
6.13 .64
6.14 .66
6.15 .68
6.16 .72
6.17 .75
6.18 .77
6.19 .80
6.20 .86
6.21 .88
7 Queryexpressions.93
7.1 .93
7.2 .97
8 Predicates.98
8.1 .98
8.2 .99
8.3 .100
8.4 .102
8.5 .103
9 Mappings.108
9.1 MappingSQLstoXMLnames.108
9.2 Mappingamulti-partSQLnametoanXMLname.111
9.3 MappingXMLnamestoSQLs.113
iv ©ISO/IEC2023–Allrightsreserved
---------------------- Page: 4 ----------------------
ISO/IEC9075-14:2023(E)
9.4 MappinganSQLdatatypetoanXMLname.115
9.5 MappingSQLdatatypestoXMLschemadatatypes.120
9.6 MappinganSQLdatatypetoanamedXMLschemadatatype.139
9.7 MappingacollectionofSQLdatatypestoXMLschemadatatypes.142
9.8 MappingvaluesofSQLdatatypestovaluesofXMLschemadatatypes.144
9.9 MappinganSQLtabletoXMLschemadatatypes.150
9.10 MappinganSQLtabletoanXMLelementorasequenceofXMLelements.154
9.11 MappinganSQLtabletoXMLandanXMLschemadocument.158
9.12 MappinganSQLschematoXMLschemadatatypes.163
9.13 MappinganSQLschematoanXMLelement.166
9.14 MappinganSQLschematoanXMLdocumentandanXMLschemadocument.169
9.15 MappinganSQLcatalogtoXMLschemadatatypes.174
9.16 MappinganSQLcatalogtoanXMLelement.176
9.17 MappinganSQLcatalogtoanXMLdocumentandanXMLschemadocument.179
10 Additionalcommonrules.184
10.1 Retrieval assignment.184
10.2 Store assignment.186
10.3 Resultofdatatypecombinations.188
10.4 Typeprecedencelistdetermination.190
10.5 Typenamedetermination.191
10.6 Determinationofidenticalvalues.192
10.7 DeterminationofequivalentXMLvalues.193
10.8 Equality operations.196
10.9 Groupingoperations.197
10.10 Multisetelementgroupingoperations.198
10.11 Orderingoperations.199
10.12 Potentialsourcesofnon-determinism.200
10.13 InvokinganSQL-invokedroutine.202
10.14 DeterminationofnamespaceURI.205
10.15 ConstructionofanXMLelement.207
10.16 ConcatenationoftwoXMLvalues.210
10.17 SerializationofanXMLvalue.211
10.18 ParsingastringasanXMLvalue.216
10.19 RemovingXQuerydocumentnodesfromanXQuerysequence.220
10.20 ConstructingacopyofanXMLvalue.222
10.21 ConstructinganunvalidatedXQuerydocumentnode.223
10.22 CreationofanXQueryexpressioncontext.224
10.23 DeterminationofanXQueryformaltypenotation.227
10.24 ValidatinganXQuerydocumentorelementnode.230
11 Additionalcommonelements.232
11.1 .232
11.2 .235
11.3 .237
11.4 .238
11.5 .239
12 Schemadefinitionandmanipulation.242
©ISO/IEC2023–Allrightsreserved v
---------------------- Page: 5 ----------------------
ISO/IEC9075-14:2023(E)
12.1 .242
12.2 .244
12.3 .245
12.4 .246
12.5 .248
12.6 .249
12.7 .250
12.8 .251
12.9 .255
13 SQL-clientmodules.256
13.1 .256
13.2 .258
13.3 Datatypecorrespondences.259
14 Data manipulation.261
14.1 .261
14.2 .263
14.3 .265
14.4 .266
14.5 .267
14.6 .268
14.7 .269
15 Controlstatements.270
15.1 .270
15.2 .272
16 Sessionmanagement.274
16.1 .274
17 DynamicSQL.275
17.1 DescriptionofSQLdescriptorareas.275
17.2 .276
17.3 .277
17.4 .278
18 EmbeddedSQL.279
18.1 .279
18.2 .284
18.3 .287
18.4 .291
18.5 .294
18.6 .297
18.7 .300
19 Call-LevelInterfacespecifications.304
19.1 SQL/CLIdatatypecorrespondences.304
20 Diagnosticsmanagement.306
20.1 .306
21 InformationSchema.307
21.1 InformationSchemadigitalartifact.307
vi ©ISO/IEC2023–Allrightsreserved
---------------------- Page: 6 ----------------------
ISO/IEC9075-14:2023(E)
21.2 NCNAME domain.307
21.3 URIdomain.308
21.4 ATTRIBUTES view.309
21.5 COLUMNSview.310
21.6 DOMAINS view.311
21.7 ELEMENT_TYPESview.312
21.8 FIELDS view.313
21.9 METHOD_SPECIFICATION_PARAMETERSview.314
21.10 METHOD_SPECIFICATIONS view.315
21.11 PARAMETERSview.316
21.12 ROUTINESview.318
21.13 XML_SCHEMA_ELEMENTS view.320
21.14 XML_SCHEMA_NAMESPACESview.321
21.15 XML_SCHEMASview.322
21.16 Shortnameviews.323
22 DefinitionSchema.333
22.1 DefinitionSchemadigitalartifact.333
22.2 DATA_TYPE_DESCRIPTORbasetable.333
22.3 PARAMETERSbasetable.339
22.4 ROUTINESbasetable.341
22.5 USAGE_PRIVILEGESbasetable.343
22.6 XML_SCHEMA_ELEMENTSbasetable.344
22.7 XML_SCHEMA_NAMESPACESbasetable.346
22.8 XML_SCHEMASbasetable.347
23 SQL/XMLXMLschema.349
24 Statuscodes.353
24.1 SQLSTATE.353
25 Conformance.355
25.1 ClaimsofconformancetoSQL/XML.355
25.2 AdditionalconformancerequirementsforSQL/XML.356
25.3 ImpliedfeaturerelationshipsofSQL/XML.357
AnnexA(informative) SQLconformancesummary.365
AnnexB(informative) Implementation-defined elements.402
AnnexC(informative) Implementation-dependent elements.417
AnnexD(informative) SQLoptionalfeaturetaxonomy.419
AnnexE(informative) Deprecatedfeatures.425
AnnexF(informative) IncompatibilitieswithISO/IEC9075:2016.426
AnnexG(informative) DefectReportsnotaddressedinthisdocument.427
Bibliography.428
Index.429
©ISO/IEC2023–Allrightsreserved vii
---------------------- Page: 7 ----------------------
ISO/IEC9075-14:2023(E)
Tables
Table Page
1 PermanentlyregisteredXMLschemas.21
2 XMLnamespaceprefixesandtheirURIs.24
3 ConstrainingfacetsofXMLschemaintegertypes.126
4 XQuerynodeproperties.194
5 DatatypecorrespondencesforAda.259
6 DatatypecorrespondencesforC.259
7 DatatypecorrespondencesforCOBOL.259
8 DatatypecorrespondencesforFortran.259
9 DatatypecorrespondencesforM.260
10 DatatypecorrespondencesforPascal.260
11 DatatypecorrespondencesforPL/I.260
12 CodesusedforSQLdatatypesinDynamicSQL.275
13 SQL/CLIdatatypecorrespondencesforAda.304
14 SQL/CLIdatatypecorrespondencesforC.304
15 SQL/CLIdatatypecorrespondencesforCOBOL.304
16 SQL/CLIdatatypecorrespondencesforFortran.305
17 SQL/CLIdatatypecorrespondencesforM.305
18 SQL/CLIdatatypecorrespondencesforPascal.305
19 SQL/CLIdatatypecorrespondencesforPL/I.305
20 SQL-statementcodes.306
21 SQLSTATEclassandsubclasscodes.353
22 ImpliedfeaturerelationshipsofSQL/XML.357
A.1 FeaturedefinitionsoutsideofConformanceRules.365
D.1 Featuretaxonomyforoptionalfeatures.419
viii ©ISO/IEC2023–Allrightsreserved
---------------------- Page: 8 ----------------------
ISO/IEC 9075-14:2023(E)
Foreword
ISO (the International Organization for Standardization) and IEC (the International Electrotechnical
Commission) form the specialized system for worldwide standardization. National bodies that are
members of ISO or IEC participate in the development of International Standards through technical
committees established by the respective organization to deal with particular fields of technical activity.
ISO and IEC technical committees collaborate in fields of mutual interest. Other international
organizations, governmental and non-governmental, in liaison with ISO and IEC, also take part in the
work.
The procedures used to develop this document and those intended for its further maintenance are
described in the ISO/IEC Directives, Part 1. In particular, the different approval criteria needed for the
different types of document should be noted. This document was drafted in accordance with the editorial
rules of the ISO/IEC Directives, Part 2 (see www.iso.org/directives or
www.iec.ch/members_experts/refdocs).
ISO and IEC draw attention to the possibility that the implementation of this document may involve the
use of (a) patent(s). ISO and IEC take no position concerning the evidence, validity or applicability of any
claimed patent rights in respect thereof. As of the date of publication of this document, ISO and IEC have
not received notice of (a) patent(s) which may be required to implement this document. However,
implementers are cautioned that this may not represent the latest information, which may be obtained
from the patent database available at www.iso.org/patents and https://patents.iec.ch. ISO and IEC shall
not be held responsible for identifying any or all such patent rights.
Any trade name used in this document is information given for the convenience of users and does not
constitute an endorsement.
For an explanation of the voluntary nature of standards, the meaning of ISO specific terms and
expressions related to conformity assessment, as well as information about ISO's adherence to the World
Trade Organization (WTO) principles in the Technical Barriers to Trade (TBT) see
www.iso.org/iso/foreword.html. In the IEC, see www.iec.ch/understanding-standards.
This document was prepared by Joint Technical Committee ISO/IEC JTC 1, Information technology,
Subcommittee SC 32, Data management and interchange.
This sixth edition cancels and replaces the fifth edition (ISO/IEC 9075-14:2016), which has been
technically revised. It also incorporates the Technical Corrigenda ISO/IEC 9075-14:2016/Cor.1:2019 and
ISO/IEC 9075-14:2016/Cor.2:2022.
The main changes are as follows:
— improve the presentation and accuracy of the summaries of implementation-defined and
implementation-dependent aspects of this document;
— introduction of several digital artifacts;
— alignment with updated ISO house style and other guidelines for creating standards.
© ISO/IEC 2023 – All rights reserved ix
---------------------- Page: 9 ----------------------
ISO/IEC 9075-14:2023(E)
This sixth edition of ISO/IEC 9075-14 is designed to be used in conjunction with the following editions of
other parts of the ISO/IEC 9075 series, all published in 2023:
— ISO/IEC 9075-1, sixth edition;
— ISO/IEC 9075-2, sixth edition;
— ISO/IEC 9075-3, sixth edition;
— ISO/IEC 9075-4, seventh edition;
— ISO/IEC 9075-9, fifth edition;
— ISO/IEC 9075-10, fifth edition;
— ISO/IEC 9075-11, fifth edition;
— ISO/IEC 9075-13, fifth edition;
— ISO/IEC 9075-15, second edition;
— ISO/IEC 9075-16, first edition.
A list of all parts in the ISO/IEC 9075 series can be found on the ISO and IEC websites.
Any feedback or questions on this document should be directed to the user’s national standards body. A
complete listing of these bodies can be found at www.iso.org/members.html and www.iec.ch/national-
committees.
x © ISO/IEC 2023 – All rights reserved
---------------------- Page: 10 ----------------------
ISO/IEC9075-14:2023(E)
Introduction
Theorganizationofthisdocumentisasfollows:
1) Clause1,“Scope”,specifiesthescopeofthisdocument.
2) Clause2,“Normativereferences”,identifiesadditionalstandardsthat,throughreferenceinthis
document,constituteprovisionsofthisdocument.
3) Clause3,“Termsanddefinitions”,definesthetermsanddefinitionsusedinthisdocument.
4) Clause4,“Concepts”,presentsconceptsrelatedtothisdocument.
5) Clause5,“Lexicalelements”,definesthelexicalelementsofthelanguage.
6) Clause6,“Scalarexpressions”,definestheelementsofthelanguagethatproducescalarvalues.
7) Clause7,“Queryexpressions”,definestheelementsofthelanguagethatproducerowsandtables
ofdata.
8) Clause8,“Predicates”,definesthepredicatesofthelanguage.
9) Clause9,“Mappings”,definesthewaysinwhichcertainSQLinformationcanbemappedintoXML
andcertainXMLinformationcanbemappedintoSQL.
10) Clause10,“Additionalcommonrules”,specifiestherulesforassignmentsthatretrievedatafrom
orstoredataintoSQL-data,andformationrulesforsetoperations.
11) Clause11,“Additionalcommonelements”,definesadditionallanguageelementsthatareusedin
variouspartsofthelanguage.
12) Clause12,“Schemadefinitionandmanipulation”,definesfacilitiesforcreatingandmanaginga
schema.
13) Clause13,“SQL-clientmodules”,definesSQL-clientmodulesandexternally-invokedprocedures.
14) Clause14,“Datamanipulation”,definesthedatamanipulationstatements.
15) Clause15,“Controlstatements”,definestheSQL-controlstatements.
16) Clause16,“Sessionmanagement”,definestheSQL-sessionmanagementstatements.
17) Clause17,“DynamicSQL”,definestheSQLdynamicstatements.
18) Clause18,“EmbeddedSQL”,definesthehostlanguageembeddings.
19) Clause19,“Call-LevelInterfacespecifications”,
20) Clause20,“Diagnosticsmanagement”,definesthediagnosticsmanagementfacilities.
21) Clause21,“InformationSchema”,definesviewedtablesthatcontainschemainformation.
22) Clause22,“DefinitionSchema”,definesbasetablesonwhichtheviewedtablescontainingschema
informationdepend.
23) Clause23,“SQL/XMLXMLschema”,definesthecontentofanXMLnamesp
...
Questions, Comments and Discussion
Ask us and Technical Secretary will try to provide an answer. You can facilitate discussion about the standard in here.