Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

how to do generate report using ICETOOL based on record type

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL
View previous topic :: :: View next topic  
Author Message
homesh_career

New User


Joined: 25 Aug 2005
Posts: 5

PostPosted: Mon Oct 20, 2008 10:03 pm    Post subject: how to do generate report using ICETOOL based on record type
Reply with quote

Hi,

I have a VSAM file (KSDS)...with LRECL 250
for example

Rectype data amount
1 aaaa 10.00
2 aadsf 20.00
1 fdgdfkl 30.00
4 dfgfd 20.00
2 dfgfd 10.00
1 iuretret 10.00
----------------------------------

The amount is in packed decimal..
and the output should be in the following format and the amount will be is a display format ..

RecType no_of_rec total_amt
1 3 50.00
2 2 30.00
4 1 20.00
------------------------------------

Please help out if this possible using ICETOOL.

Thanks in advance
Back to top
View user's profile Send private message

Frank Yaeger

DFSORT Moderator


Joined: 15 Feb 2005
Posts: 7130
Location: San Jose, CA

PostPosted: Mon Oct 20, 2008 10:24 pm    Post subject:
Reply with quote

What is the starting position, length and format of each field in the input records?

What is the starting position of each column in the output records?

Does the VSAM input file have fixed-length records or variable-length records?
Back to top
View user's profile Send private message
homesh_career

New User


Joined: 25 Aug 2005
Posts: 5

PostPosted: Mon Oct 20, 2008 10:32 pm    Post subject:
Reply with quote

Thanks for reply ...
Input Record
Field1 - position 98, Length -1, char
Field2 - data field , not required in the output
Field3 - position 73 Packed Decimal s9(10)V99
----------------------------------------
Output reocrd

Field1 Record_type char 1
Field2 No_of_records - record count in display format 99999
Field3 Total_amount - display format
---------------
VSAM file is of fixed length format with LRECL 350

Thanks
Back to top
View user's profile Send private message
Skolusu

Senior Member


Joined: 07 Dec 2007
Posts: 2205
Location: San Jose

PostPosted: Mon Oct 20, 2008 10:51 pm    Post subject:
Reply with quote

homesh_career,

Use the following DFSORT control cards


Code:

//SYSIN    DD *                                   
  SORT FIELDS=(1,1,CH,A)                         
  INREC BUILD=(98,1,73,7,23:X)                   
  OUTFIL REMOVECC,NODETAIL,                       
  SECTIONS=(1,1,                                 
  TRAILER3=(1,1,X,COUNT=(M11,LENGTH=5),X,         
            TOT=(2,7,PD,EDIT=(IIIIIIIIIIIT.TT))))
/*


The output is
Code:

1 00003           50.00
2 00002           30.00
4 00001           20.00
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Record Not found in AlX but record re... mukun264 COBOL Programming 5 Fri Mar 24, 2017 9:28 am
No new posts Count the length of the record & ... sreekusr DFSORT/ICETOOL 4 Thu Mar 23, 2017 7:52 pm
No new posts JCL to Set Return code based on DB2 S... vinu78 DB2 17 Mon Mar 13, 2017 9:47 pm
No new posts IMS DB-How to update a record (a sing... Nic Clouston IMS DB/DC 9 Thu Mar 09, 2017 4:38 pm
No new posts TSO or command line utility to genera... kishpra JCL & VSAM 3 Thu Mar 09, 2017 1:11 am


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us