What would be the result on writing a data record to a PF
file using the "WRITE" opcode after the SETON *ON *INLR
statment?
Answers were Sorted based on User's Feedback
Answer / prabhas
All files used remain opened till it executes last 'C' spec
statement
| Is This Answer Correct ? | 9 Yes | 1 No |
Answer / naveen chandra joshi
It will write the record in the database file even after LR
indicator sets on.
Program execution continues till last C specification.
| Is This Answer Correct ? | 3 Yes | 0 No |
Answer / syam
Hi Prabhas thanks....Why it is writing? Seton *On *Inlr not
closing the pf file?
| Is This Answer Correct ? | 4 Yes | 2 No |
Answer / raghavendra malwadkar
It will sucessfully write the data record to a PF and only
after executing the last record, LR indicator sets on,
hence even if you specify Seton *LR any where in the
program, the LR indicator is *ON only after executing the
last record.
Hope it suffies you concern.
| Is This Answer Correct ? | 5 Yes | 3 No |
Answer / harshad r suryawaunshi
Write statement will get executed successfully and record
will get added in the file. Program execution continues til
the last line of C specs.
| Is This Answer Correct ? | 3 Yes | 1 No |
Answer / sree
The LR indicator says, the last record in the file has
reached and hence there are no input records to process. But
this will not prevent in writing the record to file.
Please correct me if I am wrong.
| Is This Answer Correct ? | 0 Yes | 0 No |
Answer / sakshi anand
i think it will not be executed because the files is closed when we use seton lr/or the odp is closed now.
| Is This Answer Correct ? | 0 Yes | 2 No |
Answer / sakthi
all files will be closed with inlr on and we can't perform write operation on a closed file. We will get error.
| Is This Answer Correct ? | 0 Yes | 2 No |
Answer / gsp
The 'Write' statement has to be witten before
the Lr On statement.
Reason: All files are closed and program ends
as soon as Lr is on.
| Is This Answer Correct ? | 5 Yes | 10 No |
What is difference between bind by copy and bind by reference?
Can anybody tell me, does CL/400 handle LEVEL check while running the CL program....? plz share your experience...
1.How to read a subfile in out put mode? 2.what are the keywords used to share same file? 3.using composite key which rpg code used?
parameters cannot be passed in which one??
1.I have a Batch job, Running for 4 hours, i want to reduce the executing time to 2 hours what should you do?
can i use UPDDTA command in rpg program in which contains a file
How to declare the dynamic(run time) array in rpgle? can you please give example
how do I do concatenation in rpg iv, like I do in cl?
suppose there are 100 records and i want to read records between 60-70 how we can read this 10 records in rpg
How do you do indexing in a physical file?
suppose if we want to update the data in cl what we will do?
HI, 1: WHAT IS THE FUNCTION OF %KDS?WITH PROGRAMMING CODES EXAMPLE 2: WHAT IS THE FUNCTION OF Z-ADD AND Z-SUB ? WITH PROGRAMMING CODES EXAMPLE