Character and graphic strings are compatible with other character and graphic strings when there is a defined conversion between their corresponding CCSIDs.
If one operand column is... | And the other operand is... | The data type of the result column is... |
---|---|---|
CHAR(x) | CHAR(y) | CHAR(z) where z = max(x,y) |
GRAPHIC(x) | GRAPHIC(y) or CHAR(y) | GRAPHIC(z) where z = max(x,y) |
VARCHAR(x) | VARCHAR(y) or CHAR(y) | VARCHAR(z) where z = max(x,y) |
VARCHAR(x) | GRAPHIC(y) | VARGRAPHIC(z) where z = max(x,y) |
VARGRAPHIC(x) | VARGRAPHIC(y) or GRAPHIC(y) or VARCHAR(y) or CHAR(y) | VARGRAPHIC(z) where z = max(x,y) |
CLOB(x) | CLOB(y) or VARCHAR(y) or CHAR(y) | CLOB(z) where z = max(x,y) |
CLOB(x) | GRAPHIC(y) or VARGRAPHIC(y) | DBCLOB(z) where z = max(x,y) |
DBCLOB(x) | CHAR(y) or VARCHAR(y) or CLOB(y) or GRAPHIC(y) or VARGRAPHIC(y) or DBCLOB(y) | DBCLOB(z) where z = max(x,y) |
The CCSID of the result graphic string will be derived based on the Conversion rules for operations that combine strings.
(C) Copyright IBM Corporation 1992, 2006. All Rights Reserved.