how to get no of records in file in rpg with out cl cmd

Answers were Sorted based on User's Feedback



how to get no of records in file in rpg with out cl cmd..

Answer / shobhit

With the help of INFDS(File information data structure) we
can know the no of records in file.

Ex.
D NUM_RCDS 156 159I O * Num of records

Is This Answer Correct ?    44 Yes 0 No

how to get no of records in file in rpg with out cl cmd..

Answer / shobhit

Read the file from beginning and increase the counter by
one till end of file. At the last the counter value will be
the no of records in file.

Is This Answer Correct ?    5 Yes 15 No

Post New Answer

More IBM AS400 AllOther Interview Questions

What is Spool file, Why is it required?

1 Answers  


1.what is mean by compilation and runtime error? 2.How to define ALFA numeric value in pf? 3.what command is used to define a data in cl pgm? 4.What type of command is used in page at a time subfile and load all subfile?

2 Answers  


when you are defining a flat file in your program in f specs which format will you specify?

1 Answers   IBM,


how can we view the entire objects and its types in a pgm?

7 Answers   Mind Tree,


what is join logical file?

1 Answers   IBM,


How do you grant authority?

1 Answers  


we have 2 PF files with same name, how to copy data's from one file to another through RPG program logic?

3 Answers  


What does SDA stands for ?

1 Answers  


what is the function of cpysplf command?

1 Answers   IBM,


How can we read file using curser? how to define a curser?

0 Answers  


Write a CL program which will run a batch job at 1 am every night

0 Answers  


how can I control the way a remote browser uses its cache?

0 Answers   IBM,


Categories