HOW TO SELECT SOME PORTION FROM A REPORT?
Moderators: Frank Yaeger, Moderator Group
HOW TO SELECT SOME PORTION FROM A REPORT?
Hello all
I am a new member, and i am facing a problem.
I have a report which has ouput deatils of many programs, i need to pick
the data of some programs and copy it to some other PS file.
The format of the report is:
Heading and then the data.
So when i try to use sorting, it just gives me the heading.
What needs to be done so that i get the data also along with the report.
Thanks
Anubhuti
I am a new member, and i am facing a problem.
I have a report which has ouput deatils of many programs, i need to pick
the data of some programs and copy it to some other PS file.
The format of the report is:
Heading and then the data.
So when i try to use sorting, it just gives me the heading.
What needs to be done so that i get the data also along with the report.
Thanks
Anubhuti
- Frank Yaeger
- Moderator
- Posts: 812
- Joined: Sat Feb 18, 2006 5:45 am
- Location: San Jose, CA
- Contact:
You haven't given enough information for anyone to help you. You need to explain in more detail what you're trying to do. Show an example of the records in your input file and what you expect for output. Explain the "rules" for getting from input to output. Give the RECFM and LRECL of your input file. Give the starting position, length and format of each relevant field.
(I removed your other thread. There's no reason to have another thread for the same question. Just post additional information to this thread.)
(I removed your other thread. There's no reason to have another thread for the same question. Just post additional information to this thread.)
Frank Yaeger - DFSORT Development Team (IBM) - yaeger@us.ibm.com
Specialties: JOINKEYS, FINDREP, WHEN=GROUP, ICETOOL, Symbols, Migration
=> DFSORT/MVS is on the Web at http://www.ibm.com/storage/dfsort
Specialties: JOINKEYS, FINDREP, WHEN=GROUP, ICETOOL, Symbols, Migration
=> DFSORT/MVS is on the Web at http://www.ibm.com/storage/dfsort
- Frank Yaeger
- Moderator
- Posts: 812
- Joined: Sat Feb 18, 2006 5:45 am
- Location: San Jose, CA
- Contact:
Based on the information you sent me offline, here's a DFSORT job that will do what you asked for. I assumed your input file and output files have RECFM=FB and LRECL=80, but you can change the job appropriately for other attributes. The job uses DFSORT's new WHEN=GROUP function available with z/OS DFSORT V1R5 PTF UK90013 (July, 2008).
If you don't have z/OS DFSORT PTF UK90013, ask your System Programmer to install it (it's free).
For complete details on the new functions available with PTF UK90013, see:
www.ibm.com/systems/support/storage/sof ... /mvs/ugpf/
Code: Select all
//S1 EXEC PGM=ICEMAN
//SYSOUT DD SYSOUT=*
//SORTIN DD *
1PROGRAM ID : TPMN300 FSADMFIST1 ABC
REPORT ID : TPMN300.02 X
NJR COSTI
0 APPLICATION : NJR SOURCE : AB DATA TYPE : HOURS
0 -----------INPUT------------
CORP ID FIST1 RECORDS AMOUN
.
.
.
1PROGRAM ID : TPMN500 FSADMFIST1 ABC
REPORT ID : TPMN300.02 X
NJR COSTI
0 APPLICATION : NJR SOURCE : AB DATA TYPE : HOURS
0 -----------INPUT------------
CORP ID FIST1 RECORDS
.
.
.
0PROGRAM ID : TPMN400 FSADMFIST1
REPORT ID : TPMN400.01
COMMON SUSPENSE
0 APPLICATION : NJR SOURCE : AB DATA TYP
0 -----------INPUT
CORP ID FIST1 RECORDS
-JOURNAL - NJ660X1131
ACTUALS DEBITS 47,427
CREDITS 47,427
.
.
.
/*
//SORTOUT DD SYSOUT=*
//SYSIN DD *
OPTION COPY
INREC IFTHEN=(WHEN=GROUP,BEGIN=(2,12,CH,EQ,C'PROGRAM ID : '),
PUSH=(81:15,7))
OUTFIL INCLUDE=(81,7,SS,EQ,C'TPMN300,TPMN400'),
BUILD=(1,80)
/*
For complete details on the new functions available with PTF UK90013, see:
www.ibm.com/systems/support/storage/sof ... /mvs/ugpf/
Frank Yaeger - DFSORT Development Team (IBM) - yaeger@us.ibm.com
Specialties: JOINKEYS, FINDREP, WHEN=GROUP, ICETOOL, Symbols, Migration
=> DFSORT/MVS is on the Web at http://www.ibm.com/storage/dfsort
Specialties: JOINKEYS, FINDREP, WHEN=GROUP, ICETOOL, Symbols, Migration
=> DFSORT/MVS is on the Web at http://www.ibm.com/storage/dfsort
Hi
i am getting this syntex error:
Regards:
Anu
i am getting this syntex error:
Code: Select all
INREC IFTHEN=(WHEN=GROUP,BEGIN=(2,13,CH,EQ,C'PROGRAM D : '),
?
ICE007A 0 SYNTAX ERROR
PUSH=(134:2,7))
?
Anu
- Frank Yaeger
- Moderator
- Posts: 812
- Joined: Sat Feb 18, 2006 5:45 am
- Location: San Jose, CA
- Contact:
That syntax error indicates your shop doesn't have z/OS DFSORT V1R5 PTF UK90013 (July, 2008) installed. Ask your System Programmer to install it (it's free).
Why are you checking for 'PROGRAM D :'? That doesn't correspond to the input you sent me. And why would you do the PUSH for 2,7 - that would put 'PROGRAM' in every record which wouldn't allow you to select particular groups. You want to push the value that identifies the groups. In my example, that's the TPMNxxx value. You need to use the correct value for your situation.INREC IFTHEN=(WHEN=GROUP,BEGIN=(2,13,CH,EQ,C'PROGRAM D : '),
PUSH=(134:2,7))
Last edited by Frank Yaeger on Tue Nov 11, 2008 8:40 pm, edited 1 time in total.
Frank Yaeger - DFSORT Development Team (IBM) - yaeger@us.ibm.com
Specialties: JOINKEYS, FINDREP, WHEN=GROUP, ICETOOL, Symbols, Migration
=> DFSORT/MVS is on the Web at http://www.ibm.com/storage/dfsort
Specialties: JOINKEYS, FINDREP, WHEN=GROUP, ICETOOL, Symbols, Migration
=> DFSORT/MVS is on the Web at http://www.ibm.com/storage/dfsort
- Frank Yaeger
- Moderator
- Posts: 812
- Joined: Sat Feb 18, 2006 5:45 am
- Location: San Jose, CA
- Contact:
The OP has input records as shown in the job I posted. It has groups of records that have 'PROGRAM ID : TPMNxxx' starting in position 2. He wants to extract the groups of records for TPMN300 and TPMN500.It will be helpful to board member, if question details are provided here.
Frank Yaeger - DFSORT Development Team (IBM) - yaeger@us.ibm.com
Specialties: JOINKEYS, FINDREP, WHEN=GROUP, ICETOOL, Symbols, Migration
=> DFSORT/MVS is on the Web at http://www.ibm.com/storage/dfsort
Specialties: JOINKEYS, FINDREP, WHEN=GROUP, ICETOOL, Symbols, Migration
=> DFSORT/MVS is on the Web at http://www.ibm.com/storage/dfsort
- Frank Yaeger
- Moderator
- Posts: 812
- Joined: Sat Feb 18, 2006 5:45 am
- Location: San Jose, CA
- Contact:
but still same syntex problem..
And still same reason:
That syntax error indicates your shop doesn't have z/OS DFSORT V1R5 PTF UK90013 (July, 2008) installed. Ask your System Programmer to install it (it's free).
Frank Yaeger - DFSORT Development Team (IBM) - yaeger@us.ibm.com
Specialties: JOINKEYS, FINDREP, WHEN=GROUP, ICETOOL, Symbols, Migration
=> DFSORT/MVS is on the Web at http://www.ibm.com/storage/dfsort
Specialties: JOINKEYS, FINDREP, WHEN=GROUP, ICETOOL, Symbols, Migration
=> DFSORT/MVS is on the Web at http://www.ibm.com/storage/dfsort
FREE TUTORIALS
Tutorials
Free tutorials from mainframegurukul
- JCL Tutorial
Covers all important JCL concepts. - Cobol Tutorial
This tutorials covers all Cobol Topics from STRING to COMP-3. - DB2 Tutorial
DB2 Tutorial focuses on DB2 COBOL Programming. - SORT Tutorial
This Tutorial covers all important aspects of DFSORT with examples - CICS Tutorial
This CICS tutorial covers CICS concepts and CICS Basics, CICS COBOL Programming.
Interview
Mainframe Interview questions
- Cobol Interview Questions
50+ Interview Questions - JCL Interview Questions
50+ Interview Questions - DB2 Interview Questions
100+ Interview Questions - CICS Interview Questions
70+ Interview Questions - VSAM Interview Questions
27 Interview Questions
Other References
Mainframe Tools and others
- XPEDITER Reference
Explains how we can debug a program - FILEAID Reference
Explains how to browse , edit and delete datasets - Change Man Reference
Quick Start tutorial on Changeman - Abend Reference
Important Abend codes explained - FaceBook Page
MainframeGurukul FaceBook Page - LinkedIn Page
MainframeGurkul Linkedin Page