1.Can any body share me about thease opcodes with example
please.Im new for AS/400.Could u please tell me in real
senario?
1.TESTN,
2.EVAL
3.EVALR,
TIME,
4.MONITOR
5. ENDMON
6.ON-ERROR
7.COMMIT
ROLLBACK?

Answer Posted / sumit gupta

TESTN:- this opcode test whether the variable placed at
result field is numeric and return the high(HI) indicator
value as '1'. Rest LO and EQ will remain off.

Eval:- This opcode is applicable for only same type of
character. Eg:- if you want to move a character value to
numeric value then IT WILL THROUGH COMPILATION ERROR.
Bydefault, eval opcode will move from left. For eg:- let
abc=' ' then
eval abc='AAA' abc will be 'AAA '

EVALR:- same as previous diffrence is right adjust.

TIME:- This opcode will return the system time of day.

MONITOR:- this opcode is used to monitor the error in rpgle
program.

ENDMON:- This opcode is used in conjunction with MONITOR
opcode.

ON-ERROR:- This is used again wilt monitor and endmon opcode
MONITOR
ON-ERROR
ENDMON

COMMIT:- This opcode is used to commit the changes in the
file.
COMMMIT keyword is used in F-specs like
Fabc UA F DISK COMMIT(*IN03)
:
:
C If *in03='1'
C COMMIT
C ELSE
C ROLLACK
C ENDIF

If Indicator 03 is '1' then commit all the changes done in
the database file. Else rollback is done onto that database
file.

Is This Answer Correct ?    10 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

explain sflclr, sflend, sfldlt, and sflcsrrrn?

891


what is program status data structure?

1391


give an eg of ACQ-(ACQUIRE),BIT OFF,BIT ON,DEALLOC,DUMP,FEOD,FORCE,MHHZO,MHLZO,MHLLZO,MLHZO,REL,RESET,TESTZ,TESTB,TESTN----GIVE SMALL EXAMPLE TO THE OPCODES...TO UNDERSTAND FUNCTIONING...........

3289


write an RPG program to calculate the marks of 5 students (A,B, C, D, E)in 3 different subjects (eng, math, sci) an display on the screen

832


How can we know running job is batch or interactive?

659






How to select highest score of each subject or how to select highest income of every month?

1297


How many program bind in one module....

2125


during execution, an rpg/400 program automatically follows a sequence of operations for each record that is processed. The built-in program cycle includes the following logical steps.

756


can anybody help me to solve this problem. the program that i m checking display error message saying "Record format for file AJDSPFFD does not match model file and decimal error. how to solve this problem. The AJDSPFFD is snapshot the AJTLOG that is the audit trail list.

2281


How would display prime numbers using CL program?

5682


what is the use of sflnxtchg?

805


What is the purpose of record level identifier?

730


what do you mean by an input subfile, what are the keywords required?

775


What is the difference between copybooks and subprocedures in as400?

812


if there is a module object , how to find the program object for this module object.Assume the module object name and program object name is not same.

2201