Previous Topic Next topic Print topic


XML SQL Type

Note: OpenESQL and DB2 ECM only

Syntax

SQL [TYPE] [IS] XML AS CLOB(lob-length)

Where lob-length is a value between 1 and 2147483647 expressed either as a number or a number followed by K (kilobytes), M (megabytes), or G (gigabytes).

Note: Although this SQL TYPE has a theoretical size limitation of 2G, for all practical purposes, the actual limitation is approximately 450M, which is the data size actually allocated to the application program.

Example

01 hv-name SQL TYPE IS XML AS CLOB(2M).

generates

01 hv-name.
  03 hv-name-len    PIC S9(9) COMP-5.
  03 hv-name-val    PIC X(2097152).
Previous Topic Next topic Print topic