WHERE DO WE USE COMIT KEYWORD IN AN RPG PROGRAM?
YOU MADE SOME CHANGES TO DATABASE BUT YOU DON'T WANT TO
SAVE THOSE CHANGES NOW? HOW DO YOU HANDLE THIS ONE?
Answers were Sorted based on User's Feedback
Answer / shobhit
Commitment Control is a function that allows processing a
group of changes in the file as a single operation.
If you want all the changes in file use COMMIT keyword else
use ROLLBACK.
Define COMMIT keyword in continuation line of F Spec(IPFK
spec) and COMMIT opcode in C spec.
| Is This Answer Correct ? | 7 Yes | 1 No |
Answer / mansi walia
Scenario:
Suppose we have written a new record in a database file but
we want to check if the employee phone number has is not
entered then roll back the changes else comit.
Example:
Move SEmpName EmpName
Move SEmpAdd EmpAdd
Move SEmpPh EmpPh
Write EmpRec
If EmpPh <> *Zeros
COMIT
else
RollBack
EndIf
| Is This Answer Correct ? | 1 Yes | 1 No |
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?
how do u track msg in cl pgm???
How to find d key field of a pf that doesn’t have source physical file?
Can a run time array be declare like below with no specified number of elements ? Is it possible ? DFLD_ARRAY 7 DIM() INZ(*blanks) What does this mean ? Does this mean that the number of array elements will be dynamically declared during run time ?
How can we find out whether the job is interactive or Batch through RPG program? 2) How can we find out through CL program?
what is a rpg?
Suppose I have 3 jobs a b and c. I want to submit b after successful completion of a and want to submit c after successful completion of b. Without using job scheduler or job queue, how can I do that through cl program?
I have two sessions S1 & S2 under this 3 jobs(say j1,j2,j3 under session S1) And 2 jobs(Say j4, j5 Under session S2)is running. How many QTEMP & how many LDA will create for the same.
suppose there are 100 records and i want to read records between 60-70 how we can read this 10 records in rpg
Why there is invention of RPG if we can do insert update delete in CL through SQL.Why the rise of RPG?
1.Load an runtime array of length 99 from the pf and you want to handle all the possible errors?
how we retrieve records without using key field (ex:name) from Physical File through RPG in as/400?