Information technology — Database languages — SQL — Part 3: Call-Level Interface (SQL/CLI) — Technical Corrigendum 2

Technologies de l'information — Langages de base de données — SQL — Partie 3: Interface de niveau d'appel (SQL/CLI) — Rectificatif technique 2

General Information

Status
Withdrawn
Publication Date
04-Jun-2003
Withdrawal Date
04-Jun-2003
Current Stage
9599 - Withdrawal of International Standard
Completion Date
15-Dec-2003
Ref Project

Relations

Buy Standard

Standard
ISO/IEC 9075-3:1999/Cor 2:2003
English language
22 pages
sale 15% off
Preview
sale 15% off
Preview

Standards Content (Sample)

INTERNATIONAL STANDARD ISO/IEC 9075-3:1999
TECHNICAL CORRIGENDUM 2
Published 2003-06-01

INTERNATIONAL ORGANIZATION FOR STANDARDIZATION • МЕЖДУНАРОДНАЯ ОРГАНИЗАЦИЯ ПО СТАНДАРТИЗАЦИИ • ORGANISATION INTERNATIONALE DE NORMALISATION
INTERNATIONAL ELECTROTECHNICAL COMMISSION • МЕЖДУНАРОДНАЯ ЭЛЕКТРОТЕХНИЧЕСКАЯ КОМИССИЯ • COMMISSION ÉLECTROTECHNIQUE INTERNATIONALE


Information technology — Database languages — SQL —
Part 3:
Call-Level Interface (SQL/CLI)
TECHNICAL CORRIGENDUM 2
Technologies de l'information — Langages de base de données — SQL —
Partie 3: Interface de niveau d'appel (SQL/CLI)
RECTIFICATIF TECHNIQUE 2
Technical Corrigendum 2 to ISO/IEC 9075-3:1999 was prepared by Joint Technical Committee
ISO/IEC JTC 1, Information technology, Subcommittee SC 32, Data management and interchange.
ISO/IEC 9075-3:1999/Cor. 2:2003 cancels and replaces ISO/IEC 9075-3:1999/Cor. 1:2000.

Statement of purpose for rationale:

A statement indicating the rationale for each change to ISO/IEC 9075 is included. This is to inform the users of
that standard as to the reason why it was judged necessary to change the original wording. In many cases the
reason is editorial or to clarify the wording; in some cases it is to correct an error or an omission in the original
wording.
Notes on numbering:
Where this Corrigendum introduces new Syntax, Access, General and Conformance Rules, the new rules have
been numbered as follows:
Rules inserted between, for example, Rules 7) and 8) are numbered 7.1), 7.2), etc. [or 7) a.1), 7) a.2), etc.]. Those
inserted before Rule 1) are numbered 0.1), 0.2), etc.
Where this Corrigendum introduces new Subclauses, the new subclauses have b een numbered as follows:
Subclauses inserted between, for example, Subclause 4.3.2 and 4.3.3 are numbered 4.3.2a, 4.3.2b, etc.
Those inserted before, for example, 4.3.1 are numbered 4.3.0, 4.3.0a, etc.
ICS 35.060 Ref. No. ISO/IEC 9075-3:1999/Cor.2:2003(E)
©  ISO/IEC 2003 – All rights reserved
Published in Switzerland

---------------------- Page: 1 ----------------------
ISO/IEC 9075-3:1999/Cor.2:2003(E)
Contents
Page

3.1.1.Defin itions provide d in Part 3 . . . . . . 3
3.3.2.1 Clause, subclause and table relationships . . . . . . 3
4.4.5 Connection attributes . . . . . 4
5.1 . . . . . . . 4
5.3 Description of CLI item descriptor areas . . . . . 5
5.5 Implicit DESCRIBE US ING clause . . . . . 5
5.11 Deferred parameter check . . . . . 5
5.13 Description of CLI item descriptor areas . . . . . 5
5.14 Other tables associated with CLI . . . . . 6
5.15 Data type correspondences . . . . 8
6.5 BindCol . . . . . . . 9
6.6 BindParameter . . . . . . . 9
6.9 ColA ttribute . . . . . . . 9
6.10 ColumnPrivileges . . . . . 10
6.11 Columns . . . . . . . 10
6.12 Connect . . . . . . . 11
6.14 DataSources . . . . . . . 11
6.15 DescribeCol . . . . . . . 12
6.17 EndTran . . . . . . . 12
6.18 Error . . . . . . . 13
6.19 ExecDirect . . . . . . 14
6.21 Fetch . . . . . . . 14
6.22 Fetch Scroll . . . . . . . 1 5
6.23 ForeignKeys . . . . . . . 1 5
6.28 Ge tConnec tAttr . . . . . . . 16
6.29 GetCursorName . . . . . . 1 6
6.30 Ge tData . . . . . . . 1 6
6.32 GetDescRec . . . . . . . 1 6
6.34 GetDiagRec . . . . . . . 1 7
6.36 GetFeatureInfo . . . . . . . 1 7
6.40 Ge tParamD ata . . . . . . . 17
6.45 GetTyp eInfo . . . . . . . 1 8
6.50 Prepare . . . . . . . 18
6.51 PrimaryKeys . . . . . . . 18
6.54 SetC onnectA ttr . . . . . . . 19
6.55 SetCursorName . . . . . . . 19
6.56 SetD escField . . . . . . . 19
6.60 SpecialColumns . . . . . . 20
6.62 TablePrivileges . . . . . . . 20
6.63 Tables . . . . . . . 20
7.1 SQL _IMPL EME NTA TION _INFO base table . . . . . 21
A.1 C h eader file SQ LCLI.H . . . . . 23
A.2 COBOL library item SQLCLI . . . . . 23
Annex B Implem entation-de fined eleme nts . . . . . 24
2 ©  ISO/IEC 2003 – All rights reserved

---------------------- Page: 2 ----------------------
ISO/IEC 9075-3:1999/Cor.2:2003(E)
Information technology — Database languages — SQL —
Part 3:
Call-Level Interface (SQL/CLI)
TECHNICAL CORRIGENDUM 2

3.1.1.Definitions provided in Part 3
1. Rationale: Provide missing definition
Insert the following item:
a.0) data source: A synonym for the SQL-server that is part of the current connection.
3.3.2.1 Clause, subclause and table relationships
1. Rationale: Separating data type correspon dence tables in Foun dation and CL I.
Replace the following rows from Table 1 "Clause, Subclause, and Table relationships":
Clause, Subclause, or Table in this part of Corresponding Clause, Subclause, or Table from Part containing
/ISO/IEC 9075 another part correspondence
Subclause 5.15, "Data type Subclause 13.6, "Data type ISO/IEC 907 5-2
correspondences" correspondences"
Table 44, "Data type correspondences for Table 18, "Data type correspondences for ISO/IEC 907 5-2
Ada" Ada"
Table 45, "Data type correspondences for Table 18, "Data type correspondences for ISO/IEC 907 5-2
C" C"
Table 46, "Data type correspondences for Table 18, "Data type correspondences for ISO/IEC 907 5-2
COBOL" COBOL"
Table 47, "Data type correspondences for Table 18, "Data type correspondences for ISO/IEC 907 5-2
Fortran" Fortran"
Table 48, "Data type correspondences for Table 18, "Data type correspondences for ISO/IEC 907 5-2
MUMPS" MUMPS"
Table 49, "Data type correspondences for Table 18, "Data type correspondences for ISO/IEC 907 5-2
Pascal" Pascal"
Table 50, "Data type correspondences for Table 18, "Data type correspondences for ISO/IEC 907 5-2
PL/I" PL/I"
with the following rows:
Clause, Subclause, or Table in this part of Corresponding Clause, Subclause, or Table from Part containing
/ISO/IEC 9075 another part correspondence
Subclause 5.15, "SQL/CLI data type none none
correspondences"
Table 44, "SQL/CLI data type none none
correspondences for Ada"
©  ISO/IEC 2003 – All rights reserved 3

---------------------- Page: 3 ----------------------
ISO/IEC 9075-3:1999/Cor.2:2003(E)
Table 45, "SQL/CLI data type none none
correspondences for C"
Table 46, "SQL/CLI data type none none
correspondences for COBOL"
Table 47, "SQL/CLI data type none none
correspondences for Fortran"
Table 48, "SQL/CLI data type none none
correspondences for MUMPS"
Table 49, "SQL/CLI data type none none
correspon dences fo r Pascal"
Table 50, "SQL/CLI data type none none
correspondence s for PL/I"
4.4.5 Connection attributes
1. Rationale: Remove the anomaly in and correct the specification of which locators are
marked invalid when an SQL-transaction ends.
th
Replace the 5 paragraph with:
The SAVEPOINT N AME connection attribute specifies the savepoint to be referenced in an invocation of the
EndTran routine that uses the SAVEPOINT NAME ROLLBACK or SAVEPOINT N AME RELEASE
Comp letionType . The SA VEPO INT N AME attribute is set to a ze ro-length string when the SQL-co nnection is
allocated.
5.1
1. Rationale: Add missing rule.
Insert the following Syntax Rule:
8.1) There shall be no between the and the
2. Rationale: Separating data type correspon dence tables in Foun dation and CL I.
Replace Syntax Rule 12) with:
12) Let operative d ata type co rrespond ence table be the data type correspon dence table for HL as specified
in Subclause 5.15, “SQL/CLI data type correspondences”. Refer to the two columns of the operative
data type correspondence table as the “SQL data type column” and the “host data type column”.
4 ©  ISO/IEC 2003 – All rights reserved

---------------------- Page: 4 ----------------------
ISO/IEC 9075-3:1999/Cor.2:2003(E)
5.3 Description of CLI item descriptor areas
1. Rationale: Separating data type correspon dence tables in Foun dation and CL I.
Replace General Rule 6) with:
6) Let HL be the stand ard program ming lang uage of the in voking h ost program . Let operative data type
correspo ndence ta ble be the data type correspon dence table for HL as specified in Subclause 5.15,
“SQL/CLI data type correspondences”. Refer to the two columns of the operative data type
correspondence table as the SQL data type column and the host data type column.
5.5 Implicit DESCRIBE USING clause
1. Rationale: Editorial - typographic error.
Replace General Rule 5) c) iv) 1) with:
5) c) iv) 1) If TYPE indicates a , then LENGTH is set to the length or
maximum length in characters of the character string. OCTET_LENGTH is set to the
maximum p ossible length in octets of the character string. If HL is C, then the lengths
specified in LENGTH and O CTET_LENGT H do not include the implementation-defined
null character that terminates a C character string. CHARACTER_SET_CATALOG,
CHARA CTER_SET_SCH EMA, and CHAR ACTER_SET_N AME are set to the
of the character string’s character set. COLLATION_CATALOG,
COLLATION _SCHEMA , and COLLATION_NA ME are set to the of
the character string’s collation.
5.11 Deferred parameter check
1. Rationale: Editorial - style error.
Replace General Rule 4) with:
4) Let L2 be the set of all allocated SQL-statements in L1 that have an associated deferred parameter
number.
5.13 Description of CLI item descriptor areas
1. Rationale: Remove mangled text
Replace Syntax Rule 5) c) xiv) with:
5) c) xiv) TYPE indicates A RRA Y or AR RAY LOCA TOR , the value of C ARD INAL ITY is a va lid
value for the cardinality of a n array, there is e xactly one immediate ly subordin ate
descriptor area of IDA, and that item descriptor area is valid.
2. Rationale: Editorial - misplaced row.
Delete the following row from Table 6 — Fields in SQL/CLI row and parameter descriptor areas
©  ISO/IEC 2003 – All rights reserved 5

---------------------- Page: 5 ----------------------
ISO/IEC 9075-3:1999/Cor.2:2003(E)
Field Data Type
Fields in item descriptor areas
COUNT SMALLINT
Insert the following row into Table 6 — Fields in SQL/CLI row and parameter descriptor areas
Field Data Type
Header fields
COUNT SMALLINT
5.14 Other tables associated with CLI
1. Rationale: Correct the specification of which locators are marked invalid when an SQL-transaction ends.
In Table 14 — Codes used for transaction termination, replace the row:
Termination type Code
SAVE POINT N AME COM MIT 2
with:
Termination type Code
SAVEPOINT NAME ROLLBACK 2
2. Rationale: Remove the anomaly in .
In Table 14 — Codes used for transaction termination, delete the following rows:
Termination type Code
SAVE POINT N UMB ER CO MM IT 3
SAVEPOINT NUM BER RELEASE 5
In Table 16 — Codes used for connection attributes, delete the following row:
Attribute Code May be set
SAVEPOINT NUMBER 10028 Yes
6 ©  ISO/IEC 2003 – All rights reserved

---------------------- Page: 6 ----------------------
ISO/IEC 9075-3:1999/Cor.2:2003(E)
In Table 19 — Data types of attributes, delete the following row:
Attribute Data type Values
Statement attributes
SAVEPOINT NUMBER INTEGER Not specified
3. Rationale: Correct th e contents o f the Type co lumn of Ta ble 20 "Co des used fo r descripto r fields".
In Table 20 — Codes used for descriptor fields, delete the following rows:
Field Code SQL Item Descriptor Name Type
CARDINALITY 1040 CARDINALITY Status
CURRENT_TRANSFORM_GROUP 1039 (Not applicable) Status
DEGREE 1041 DEGREE Status
RETURNED_CARDINALITY_ 1043 RETURNED_CARDINALITY Status
POINTER
SCOPE_CATALOG 1033 SCOPE_CATALOG Status
SCOPE_NAME 1035 SCOPE_NAME Status
SCOPE_SCHEMA 1034 SCOPE_SCHEMA Status
SPECIFIC_TYPE_CATALOG 1036 (Not applicable) Status
SPECIFIC_TYPE_NAME 1038 (Not applicable) Status
SPECIFIC_TYPE_SCHEMA 1037 (Not applicable) Status
In Table 20 — Codes used for descriptor fields, add the following rows:
Field Code SQL Item Descriptor Name Type
CARDINALITY 1040 CARDINALITY Item
CURRENT_TRANSFORM_GROUP 1039 (Not applicable) Item
DEGREE 1041 DEGREE Item
RETURNED_CARDINALITY_ 1043 RETURNED_CARDINALITY Item
POINTER
SCOPE_CATALOG 1033 SCOPE_CATALOG Item
SCOPE_NAME 1035 SCOPE_NAME Item
SCOPE_SCHEMA 1034 SCOPE_SCHEMA Item
SPECIFIC_TYPE_CATALOG 1036 (Not applicable) Item
©  ISO/IEC 2003 – All rights reserved 7

---------------------- Page: 7 ----------------------
ISO/IEC 9075-3:1999/Cor.2:2003(E)
SPECIFIC_TYPE_NAME 1038 (Not applicable) Item
SPECIFIC_TYPE_SCHEMA 1037 (Not applicable) Item
4. Rationale: Add the missing codes.
In Table 37 — Codes used for concise data types, add the following rows:
Date Type Code
USER-DEFINED TYPE 17
ROW 19
ARRAY 50
5.15 Data type correspondences
1. Rationale: Separating data type correspon dence tables in Foun dation and CL I.
Change the name of this subclause to "SQL/CLI data type correspondences".
2. Rationale: Separating data type correspon dence tables in Foun dation and CL I.
st
In the Function replace the 1 paragraph with:
Replace first paragraph Specify the SQL/C LI data type correspon dences fo r SQL d ata types an d host
language types associated with the required parameter mechanisms, as shown in Table 3, “Supported calling
conventions of SQL/CLI routines by language”.
3. Rationale: Separating data type correspon dence tables in Foun dation and CL I.
In the Tables section:
Replace the title of Table 44 — "Data type correspondences for Ada" with:
Table 44 — "SQ L/CLI data type correspondences for Ada".
Replace the title of Table 45 — "Data type correspondences for C" with:
Table 45 — "SQ L/CLI data type correspondences for C".
Replace the title of Table 46 — "Data type correspondences for COBOL" with:
Table 46 — "SQ L/CLI data type correspondences for COBO L".
Replace the title of Table 47 — "Data type correspondences for Fortran" with:
Table 47 — "SQ L/CLI data type correspondences for Fortran".
Replace the title of Table 48 — "Data type correspondences for MUMPS" with:
Table 48 — "SQ L/CLI data type correspondences for MUM PS".
Replace the title of Table 49 — "Data type correspondences for Pascal" with:
Table 49 — "SQ L/CLI data type correspondences for Pascal".
8 ©  ISO/IEC 2003 – All rights reserved

---------------------- Page: 8 ----------------------
ISO/IEC 9075-3:1999/Cor.2:2003(E)
Replace the title of Table 50 — "Data type correspondences for PL/I" with:
Table 50 — "SQ L/CLI data type correspondences for PL/I".
6.5 BindCol
1. Rationale: Separating data type correspon dence tables in Foun dation and CL I.
Replace General Rule 8) with:
8) Let HL be the stand ard program ming lang uage of the in voking h ost program . Let operative data type
correspo ndence ta ble be the data type correspon dence table for HL as specified in Subclause 5.15,
“SQL/CLI data type correspondences”. Refer to the two columns of the operative data type
correspo ndence ta ble as the SQL data type column and the host data type column.
6.6 BindParameter
1. Rationale: Separating data type correspon dence tables in Foun dation and CL I.
Replace General Rule 9) with:
9) Let HL be the stand ard program ming lang uage of the in voking h ost program . Let operative data type
correspo ndence ta ble be the data type correspon dence table for HL as specified in Subclause 5.15,
“SQL/CLI data type correspondences”. Refer to the two columns of the operative data type
correspo ndence ta ble as the SQL data type column and the host data type column.
6.9 ColAttribute
1. Rationale: Correct definition of parameter length.
Replace the Definition with:
ColAttribute (
StatementHandle   IN INTEGER,
ColumnNumber    IN SMALLINT,
FieldIdentifier   IN SMALLINT,
CharacterAttribute OUT CHARACTER(L),
BufferLength    IN SMALLINT,
StringLength    OUT SMALLINT,
NumericAttribute  OUT INTEGER )
RETURNS SMALLINT
where L has a max imum va lue equal to th e impleme ntation-define d maxim um length of a variable-le ngth
character string.
©  ISO/IEC 2003 – All rights reserved 9

---------------------- Page: 9 ----------------------
ISO/IEC 9075-3:1999/Cor.2:2003(E)
6.10 ColumnPrivileges
1. Rationale: Correct definition of parameter length.
Replace the Definition with:
ColumnPrivileges (
StatementHandle   IN INTEGER,
CatalogName     IN CHARACTER(L1),
NameLength1     IN SMALLINT,
SchemaName     IN CHARACTER(L2),
NameLength2     IN SMALLINT,
TableName      IN CHARACTER(L3),
NameLength3     IN SMALLINT,
ColumnName     IN CHARACTER(L4),
NameLength4     IN SMALLINT )
RETURNS SMALLINT
where each o f L1, L2, L3, and L4 has a max imum va lue equal to th e impleme ntation-defin ed maxim um length
of a variable-length character string.
6.11 Columns
1. Rationale: Correct definition of parameter length.
Replace the Definition with:
Columns (
StatementHandle   IN INTEGER,
CatalogName     IN CHARACTER(L1),
NameLength1     IN SMALLINT,
SchemaName     IN CHARACTER(L2),
NameLength2     IN SMALLINT,
TableName      IN CHARACTER(L3),
NameLength3     IN SMALLINT,
ColumnName     IN CHARACTER(L4),
NameLength4     IN SMALLINT )
RETURNS SMALLINT
where each o f L1, L2, L3, and L4 has a max imum va lue equal to th e impleme ntation-defin ed maxim um length
of a variable-length character string.
10 ©  ISO/IEC 2003 – All rights reserved

---------------------- Page: 10 ----------------------
ISO/IEC 9075-3:1999/Cor.2:2003(E)
6.12 Connect
1. Rationale: Correct definition of parameter length.
Replace the Definition with:
Connect (
ConnectionHandle  IN INTEGER,
ServerName     IN CHARACTER(L1),
NameLength1     IN SMALLINT,
UserName      IN CHARACTER(L2),
NameLength2     IN SMALLINT,
Authentication   IN CHARACTER(L3),
NameLength3     IN SMALLINT )
RETURNS SMALLINT
where
:
— L1 has a maximum value of 128.
— L2 has a max imum va lue equal to th e impleme ntation-defin ed maxim um length of a variable-le ngth
character string.
— L3 has an implementation-defined maximum value.
6.14 DataSources
1. Rationale: Correct definition of parameter length.
Replace the Definition with:
DataSources (
EnvironmentHandle  IN INTEGER,
Direction      IN SMALLINT,
ServerName     OUT CHARACTER(L1),
BufferLength1    IN SMALLINT,
NameLength1     OUT SMALLINT,
Description     OUT CHARACTER(L2),
BufferLength2    IN SMALLINT,
NameLength2     OUT SMALLINT )
RETURNS SMALLINT
where L1 and L2 have maximum values equal to the implementation-defined maximum length of a variable-
length character string.
©  ISO/IEC 2003 – All rights reserved 11

---------------------- Page: 11 ----------------------
ISO/IEC 9075-3:1999/Cor.2:2003(E)
6.15 DescribeCol
1. Rationale: Correct d efinition of par ameter len gth
Replace the Definition with:
DescribeCol (
StatementHandle   IN INTEGER,
ColumnNumber     IN SMALLINT,
ColumnName      OUT CHARACTER(L),
BufferLength     IN SMALLINT,
NameLength      OUT SMALLINT,
DataType       OUT SMALLINT,
ColumnSize      OUT INTEGER,
DecimalDigits    OUT SMALLINT,
Nullable       OUT SMALLINT )
RETURNS SMALLINT
where L has a max imum va lue equal to th e impleme ntation-define d maxim um length of a variable-le ngth
character string.
6.17 EndTran
1. Rationale: Remove the anomaly in and correct the specification of which locators are
marked invalid when an SQL-transaction ends.
Replace General Rule 13) with:
13) If CT indicates SAVEPOINT NAME R ELEASE, then:
a) If HT is not CO NNE CTIO N HA NDL E, then an e xception c ondition is raise d: CLI-spe cific
condition — invalid han dle.
b) Let SP be the value of the SA VEPO INT NA ME con nection attribute of C.
c) If SP does not specify a
...

Questions, Comments and Discussion

Ask us and Technical Secretary will try to provide an answer. You can facilitate discussion about the standard in here.