How to update only a field of a PF in an RPG program.
I don't want to update the record, only one field.
Answers were Sorted based on User's Feedback
If file FileA has fields field1, field2, field3, and we
want to write out field2 only ...
C...except..Change
OfileA...E...Change
O...............field2
Hope it will work fine.
For Free Format try out following...
Update Recformat %fields(field2);
| Is This Answer Correct ? | 33 Yes | 1 No |
Answer / kapil kumar
Use CHAIN for that record
then EVAL fld='value'
UPDATE pfrecfmt
| Is This Answer Correct ? | 1 Yes | 24 No |
difference between CHAIN and READE?
when will come session device error?
I have file with data as follows data 1 2 3 4 5 I need to read 1 and 5 ,then 2 and 4 then like.. upto end of file, can any one help on this
How do you code file / field renames in ILE 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?
what procedure should we use to find whether the following operations are successful or not setll setgt chain read reade readp pls tell with example i'm not lazy to read the manual or not lazy to do anything.but sometimes i cannot understand the things given in manual in high level english its little bit complicated for me,i can't understand their way of writing thats why i ask these questions here and find the solution in simple words that i can understand thats the real reason sir.sorry if i had hurt you or disturbed you.please understand my situation.
Whether a module can consists of many procedures or it can consist of subprocedures having a main procedure?If it is possible that it can contain many individual procedures than can we have different name for complete module and how do we call this module in main modul?
Mr.Sidc sirfor my question{how to convert date format from one format to another i think in CL/400 its CVTDAT,Please tell in RPG/400 sir not in RPGILE} you have answered using MOVE opcode,can you illustrate me with a small example sir very kind of you.
In case if I want to know whether a record exists in a file, which one do you prefer CHAIN or a SETLL and why ?
One of the job in subsystem is in Running status,expected time to complete this job is 2 minutes. But from last 5 -10 minutes this job is still in running status....What are the possible reasons...and What are the actions i need to perform to check this...?
How can i check the object existance in RPG program without using QCMDEXC command.
1.Suppose my file has 10 fields and I want to make the 2nd field Zeros in all records. And assume I have millions of records and I dont want to read each record and update the desired field with 0. Any other way to do this in one step operation? 2. Assume my file has 100 records and I want to see only first 10 records. Is this possible through LF? 3.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? 4.What is difference between Bind by copy and bind by reference?