Count the lines of codes in a program and sort.

SyncSort's Sort Product, SyncTool for z/OS, SYNCINIT and SYNCLIST.
Post Reply
User avatar
Angel
Registered Member
Posts: 93
Joined: Sat Jun 08, 2013 8:13 pm

Count the lines of codes in a program and sort.

Post by Angel »

Hi,

I'm trying to find out a way of knowing the lines of codes in my program using SyncSort. Actually, for a repository purpose, we've to maintain the lines of codes for a given program and this is a regular task. Could someone please suggest how to proceed?
zprogrammer
Global Moderator
Global Moderator
Posts: 588
Joined: Wed Nov 20, 2013 11:53 am
Location: Mars

Re: Count the lines of codes in a program and sort.

Post by zprogrammer »

Try this

Code: Select all

//S1    EXEC  PGM=SORT                                        
//SYSOUT    DD  SYSOUT=*                                      
//SORTIN DD DSN=<INPUT FILE>,DISP=SHR                                
//SORTOUT DD SYSOUT=*                                          
//SYSIN    DD    *                                            
  SORT FIELDS=COPY                                              
  OUTFIL REMOVECC,                                              
  TRAILER1=('NUMBER OF LINES IN PROGRAM :',COUNT=(M11,LENGTH=8))      
/*
zprogrammer
User avatar
Angel
Registered Member
Posts: 93
Joined: Sat Jun 08, 2013 8:13 pm

Re: Count the lines of codes in a program and sort.

Post by Angel »

Thanks Pandora. This code helps me.

Thanks.
Post Reply

Create an account or sign in to join the discussion

You need to be a member in order to post a reply

Create an account

Not a member? register to join our community
Members can start their own topics & subscribe to topics
It’s free and only takes a minute

Register

Sign in

Return to “SyncSort, SyncTool, SyncGener.”