|
%DecPos( numeric expression )
%Elem( table, array or mult-occur data struct )
%Len( expression )
%Size( variable, literal, array, table, dsn-name )
|
%Mseconds( number ) |
} |
Use instead of ADDDUR, SUBDUR Newdate = Duedate + %Days(23) |
|
%Seconds( number ) |
||
|
%Minutes( number ) |
||
|
%Hours( number ) |
||
|
%Days( number ) |
||
|
%Months( number ) |
||
|
%Years( number ) |
%Date( { expression { : date-format
} }) – to date
%Diff( op1 : op2 : duration code )
%Subdt( value : duration code ) (use
%Trim!!)
%Time({ expression : { : time-format
}})
%Timestamp({ expression : { : *ISO | *ISO0 }})
%Char( expression { : date/time fmt })
– from date
charvar = %char( Datdatatyp : *
%Dec( num/char expr { : precision
: dec places })
%DecH
%Editc( numeric : editcode { : cur-symbol })
%EditFlt( numeric expression )
%Editw( numeric : editword )
%Float( num/char expression )
%Graph( expression { : ccsid })
%Int( num/char expression )
%IntH( num/char expression )
%Str( basing-ptr { : max-len })
( right-hand-side )
%Str( basing-ptr : max-len )( left-hand-side )
%UCS2( expression )
%Uns( num/char expression )
%UnsH ( num/char expression )
|
Built-in
function |
When to
use |
Equivalent
Indicator |
|
%Eof |
Read, Readc, |
EQ |
|
%Found |
Chain, Delete, Setgt, Check, CheckR, Scan (but not
%Scan) |
GT |
|
%Equal |
Setll, Lookup |
exact match |
|
%Error |
Operations with ‘E’ |
LT |
|
%Status |
|
INFDS *Status |
%Fields( name {
: name… } )
%Kds( data-structure-name
{: number-of-keys })
%Lookup( arg
: array { : startidx { : numelems }}
)
%LookupGt
%LookupGe
%LookupLt
%LookupLe
%Occur( dsn-name
)
%Open( file
)
%TLookup( arg
: search-table { : alt-table })
%TLookupGt, %TLookupGe, %TLookupLt, %TLookupLe
%Xfoot( array-expression
)
%Abs( numeric
expression )
%Div( numerator
: denominator )
%Rem( numerator
: denominator )
%Sqrt( numeric
expression )
%Addr( variable
)
%Alloc( num )
%PAddr( string
| prototype )
%Realloc( ptr
: num )
%Check( comparator
: base { : start } )
%CheckR( comparator
: base { : start })
%Replace( replstring
: srcstring { : startpos { : src
len to replace }} )
%Scan( search
arg : source string { : start })
%Subst( string
: start { : length })
%Trim( string
)
%TrimL( string
)
%TrimR( string
)
%Xlate( from
: to : string { : startpos })
%Bitand( expression : expression
{: expression… } )
%Bitnot( expression )
%Bitor( expression : expression
{: expression … } )
%Bitxor( expression : expression )
%NullInd( fieldname )
%Parms
%Shtdn
%This