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
 

 

Formatting the records

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

New User


Joined: 26 Dec 2010
Posts: 4
Location: HYDERBAD

PostPosted: Thu Dec 30, 2010 12:24 pm    Post subject: Formatting the records
Reply with quote

Using the sort Can I do the below.
Code:

USING THE SORT CAN I DO THE BELOW.
STORE BEGIN AAAAA                 
ITEM-NUMBER ITEM-DESC             
11111       XXXXXXXXXXXXXXXXXXXXXX
            XXXXXXXXXXXXXXXXXXXXXX
            XXXXXXXXXXXXXXXXXXXXXX
22222       YYYYYYYYYYYYYYYYYYYYYY
            YYYYYYYYYYYYYYYYYYYYYY
33333       ZZZZZZZZZZZZZZZZZZZZZZ
END OF STORE AAAAA               
STORE BEGIN BBBBB                 
ITEM-NUMBER ITEM-DESC             
11111       XXXXXXXXXXXXXXXXXXXXXX
            XXXXXXXXXXXXXXXXXXXXXX
            XXXXXXXXXXXXXXXXXXXXXX
22222       YYYYYYYYYYYYYYYYYYYYYY
            YYYYYYYYYYYYYYYYYYYYYY
33333       ZZZZZZZZZZZZZZZZZZZZZZ                                     
END OF STORE BBBBB                                                     
.                                                                       
.                                                                       
I WANT THE O/P TO BE: EACH ITEM TO BE IN ONE LINE ALONG WITH THE STORE N
                                                                       
STORE-NUMBER ITEM-NUMBER ITEM-DESC                                     
AAAAA        11111       XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
AAAAA        22222       YYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYY
AAAAA        33333       ZZZZZZZZZZZZZZZZZZZZZZ                         
BBBBB        11111       XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
BBBBB        22222       YYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYY
BBBBB        33333       ZZZZZZZZZZZZZZZZZZZZZZ                         
.                                                                       
.                                                                       
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: Fri Dec 31, 2010 12:14 am    Post subject:
Reply with quote

What is the RECFM and LRECL of the input file?

Please run this job and show the //SYSOUT messages you receive, so I can see what level you're at:

Code:

//S1    EXEC  PGM=SORT
//SYSOUT    DD  SYSOUT=*
//SORTIN DD *
RECORD
//SORTOUT DD DUMMY
//SYSIN    DD    *
    OPTION COPY
/*
Back to top
View user's profile Send private message
mahesh reddy

New User


Joined: 26 Dec 2010
Posts: 4
Location: HYDERBAD

PostPosted: Sun Jan 02, 2011 9:56 pm    Post subject: Reply to: Formatting the records
Reply with quote

The i/p file RECFM is FB and the record length is 80 bytes.

All I need is, there should be only one record for each item along with the store number and the whole description. So the o/p record length can be variable based on the length of the description i.e dpends on the how many lines the item has description.
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: Sun Jan 02, 2011 11:31 pm    Post subject:
Reply with quote

If you can't/won't supply the information I ask for, I can't help you.

Please show me the //SYSOUT messages from the job I posted.

Quote:
All I need is, there should be only one record for each item along with the store number and the whole description. So the o/p record length can be variable based on the length of the description i.e dpends on the how many lines the item has description.


This is very vague. How am I supposed to know the maximum number of descriptions an item number can have? How am I supposed to know the maximum length of the output records? When you say "variable length", I don't know if you mean RECFM=VB, or RECFM=FB with blank padding.

You need to do a better job of describing what you need before I can help you.
Back to top
View user's profile Send private message
V S Amarendra Reddy

Active User


Joined: 13 Sep 2006
Posts: 200
Location: USA

PostPosted: Mon Jan 03, 2011 9:25 am    Post subject:
Reply with quote

Hi Mahesh,

Frank is asking for the below points to help you out.

1. Run the test job he mentioned in the first post so that he will be able to know which DFSORT version and release is used at your shop.

2.Mention your outputfile attributes clearly. Like let's say for your requirement, the output file should be variable, but again a variable file should have the maximum length. So please mention what is your LRECL used for the output file in your JCL step. So LRECL,RECFM are the must attributes to be provided along with the post while you are seeking for help.

3.Mention the maximum number of item descriptions that you can have in the input file.

4. I think it would be better if you can mention the LRECL and RECFM if the input file as well.

you can always find the latest functionalities used in DFSORT in Frank's signature.

Regards
Amar
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 Check if any Detail records and extra... V S Amarendra Reddy SYNCSORT 19 Mon May 08, 2017 8:54 pm
No new posts Formatting VB File Learncoholic DFSORT/ICETOOL 3 Mon Mar 20, 2017 12:29 pm
No new posts Join giving more records than expected Danielle.Filteau SYNCSORT 2 Thu Mar 09, 2017 3:28 am
No new posts TSO or command line utility to genera... kishpra JCL & VSAM 3 Thu Mar 09, 2017 1:11 am
No new posts Extract set of records matching on ac... bhaskar_kanteti DFSORT/ICETOOL 3 Mon Mar 06, 2017 7:19 am


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