I am getting error in CL program when trying to declare tablewith "Graphic field". Type "GRAPH"
DCLF FILE(MYTABLE)
Is there any way around this?
OS: V7R4M0
CL doesn't handle graphic types, you can find workarounds in the message full help :
Message . . . . : Graphic field not allowed for variable &1.
Cause . . . . . : A graphic field was found, but ALWGRAPHIC(*NO) on the DCLF command was defaulted or specified.
Recovery . . . : Specify ALWGRAPHIC(*YES) on the DCLF command, or specify a file or record format that does not contain graphic fields.
ALWGRAPHIC(*YES)
will create a CHAR(x)
that will be large enough to contain any binary value of DESC
.
If you have to use DESC
(compare, modify, ...), it would be better to use a language that knows graphic types.