How to know the number of records in a pf through clp program?

Answers were Sorted based on User's Feedback



How to know the number of records in a pf through clp program?..

Answer / syam

My above both answer is CL Command
for CL Program use this code (RTVMBRD - Retrive Member
Description)

PGM
DCL &NBRRCD TYPE(*DEC) LEN(10 0)

RTVMBRD FILE(FILLIB/FILEA1) MBR(*FIRST)
NBRCURRCD(&NBRRCD)
ENDPGM

Is This Answer Correct ?    83 Yes 1 No

How to know the number of records in a pf through clp program?..

Answer / mallela78

RTVMBRD FILE(ITMRVA) NBRCURRCD(&RCDCNT1)

Is This Answer Correct ?    13 Yes 1 No

How to know the number of records in a pf through clp program?..

Answer / syam

The correct answer...
use command DSPFD FILE(LIBOBJ/FILEA1) then Enter
then PGDOWN to last there u can see no.of records

Total number of
members . . . . . . . . . : 1
Total number of members not
available . . : 0
Total records . . . . . . . . . . . . . . :
2488

Is This Answer Correct ?    18 Yes 11 No

How to know the number of records in a pf through clp program?..

Answer / ashok

pgm
declare the file
runqry with output form as *SUMMARY parameter
endpgm

Is This Answer Correct ?    12 Yes 8 No

How to know the number of records in a pf through clp program?..

Answer / karthik

This is the EXACT CODE if you have any doubt.... mail me@
Gatlakarthik@gmail.com

DCL VAR(&R1) TYPE(*DEC) LEN(10 0)
DCL VAR(&D1) TYPE(*CHAR) LEN(2)
DCLF FILE(PF12) RCDFMT(RCD1)
RTVMBRD FILE(PF12) NBRCURRCD(&R1)
CHGVAR VAR(&D1) VALUE(&R1)
SNDPGMMSG MSG(&D1)

Is This Answer Correct ?    5 Yes 2 No

How to know the number of records in a pf through clp program?..

Answer / ravi shankar porwal

U can also find out the total no of record in a pf using
the OPNQRYF Commond in CL Pgm.

Is This Answer Correct ?    1 Yes 3 No

How to know the number of records in a pf through clp program?..

Answer / syam

Very simple....just copy pf file to another pf file.
after copy system will display subfile message on
last line of display move cursor to last line
24th line on the monitor then press PGDown key 2 times
"2488 records copied from member SALEDT."

CPYF FROMFILE(LIBOBJ/FILEA1) TOFILE(LIBOBJ/FILEA2) MBROPT
(*ADD) CRTFIL(*YES).

Is This Answer Correct ?    1 Yes 19 No

Post New Answer

More IBM AS400 AllOther Interview Questions

how can we run a batch job?

0 Answers   IBM,


difference between sflrcdnbr and sflnxtchg?

0 Answers   IBM,


How many primary files allowed in a program?

1 Answers  


in which specification the report layout can be defined?

1 Answers   IBM,


explain the difference between defining subfile and message-subfile?

1 Answers   IBM,






The content of Physical file is as below: hfcftp wruquief SENDPASV 0 CDUP ASCII GET 01100901.CSV ramndk/ECP505.EC0110090 (REPLACE QUIT Thw above commands will get executed when we call STRTCPFTP from CL program.... Now if I want to use SFTP what can be the solution? plz reply in detail....Thank you for ny help...

1 Answers  


Hello friends, i am new to AS/400. Can any one help me in AS/400 i meant say can you send me some FAQS and interview questions.

7 Answers   HanceInc, IBM,


what is the purpose of DMPCLPGM IN CL?

3 Answers   IBM, Wipro,


1)In a pf if we delete a record then how to insert a new record at the same place in that pf?? any logic or code? 2)A batch job is taking a lot of time to run,found that it is going into loop and wrapping up so how to skip that loop and process the job without changing the code? 3)In which scenario C D I R comes and C D G F comes in a job? 4)If a job came to error while processing a file how we can know at which record the error hit and how to skip that record and process other records without changing program code?

0 Answers   JDA,


What Does 'sr' In Columns 7-8 Of C Specs Mean?

1 Answers   IBM,


what is externally described file ?

1 Answers   IBM,


how do you read data area in an rpg program?

1 Answers   IBM,


Categories