11.07.2015 Views

Caché ObjectScript Reference - InterSystems Documentation

Caché ObjectScript Reference - InterSystems Documentation

Caché ObjectScript Reference - InterSystems Documentation

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

System and Other FunctionsSee Also• $ASCII function• $ZLCHAR function• $ZWASCII function$ZLCHARReturns the requested four-byte string.$ZLCHAR(n)$ZLC(n)ParameternA positive integer that can be specified as a value, a variable, or an expression.Description$ZLCHAR returns a four-byte string for n.Notes$ZLASCII and $ZLCHARThe $ZLASCII function is the logical inverse of $ZLCHAR. For example:SET x=$ZLASCII("abcd")WRITE !,xSET y=$ZLCHAR(x)WRITE !,yGiven “abcd” $ZLASCII returns 1684234849. Given 1684234849 $ZLCHAR returns “abcd”.$ZLCHAR, $ZWCHAR, and $CHAR$ZLCHAR is similar to the $CHAR function, except that it operates on 32–bit double wordsrather than 8–bit bytes. To operate on 16–bit words, use the $ZWCHAR function.$ZLCHAR is the functional equivalent of the following form of $CHAR:SET n=$ZLASCII("abcd")WRITE !,nWRITE !,$CHAR(n#256,n\256#256,n\(256**2)#256,n\(256**3))546 <strong>Caché</strong> <strong>ObjectScript</strong> <strong>Reference</strong>

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!