Hey,
What is the difference between SCAN,CHECK,XLATE OPCODES?
please give me the answeres with example in real time
senario?
Answer Posted / swadesh
SCAN:this allows to locate a character or string of
character within a character field.e.g if we want a string
like 'abc'exist in a base string like 'mnoabcd'or not.
fact1 opcode fact2 result hi lo eq
'abc' scan 'mnoabcd' var-name 90
value of var_name=4 & indicator 90 will be on.
CHECK:this is just opposite of scan.findout absence of
character or string of character.
fact1 opcode fact2 result hi lo eq
'123456' check '111*1' var-name 90
value of var_namr=4 & indicator 9 will be off on this
position.
XLATE:convert to upercase charecter to lowercase character
or vice-varsa.
declare in input specification as record identification
codes.
I 'ABCDEFGHIJKLMNOPQRSTUV C UC
I WXYZ'
I 'abcdefghijklmnopqrstuv C LC
wxyz'
then uses in c-spec.
c UC:LC xlate any-name result length_dec
if fact2 is-RAHUL u will get rahul.
| Is This Answer Correct ? | 40 Yes | 1 No |
Post New Answer View All Answers
What Does Lokup Does In Tables & Arrays?
What is RETURN CURSER LOCATION in subfile?
can error messages as a result of a comp, range or values keyword be overridden?
what do we can do with the embedded sql statements?
records can be read/update/deleted with which file?
how can you check for a records existence without causing and i/o (chain/read)?
what does the ovrdbf command do?
where can you specify an indicator in lokup operation?
is it possible to create a physical file without dds?
How do you check object lock
explain the purpose of keep and assume keywords?
difference between sflrcdnbr and sflnxtchg?
how do you use commitment control in rpg program ?
how do handle file exception/error?
what is the command used to invoke rlu ?