IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Compare JCL with record length 2000


IBM Mainframe Forums -> JCL & VSAM
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
Habeeb Shaik

New User


Joined: 29 Aug 2005
Posts: 10

PostPosted: Tue Nov 18, 2008 1:42 pm
Reply with quote

Hi,
Can any give me a JCL for comparing two flat files, each of record lenth 2000. The output should be of lenth 2000.
I have used super c but the result is of 133 chars lenth.

//SUPERC EXEC PGM=ISRSUPC,
// PARM=(DELTAL,LINECMP,
// ' NOSEQ',
// '')


thanks,
Habeeb.
Back to top
View user's profile Send private message
Escapa

Senior Member


Joined: 16 Feb 2007
Posts: 1399
Location: IL, USA

PostPosted: Tue Nov 18, 2008 2:17 pm
Reply with quote

You can use utilities like sort on output file generated from ISRSUPC to change LRECL.
Back to top
View user's profile Send private message
Habeeb Shaik

New User


Joined: 29 Aug 2005
Posts: 10

PostPosted: Tue Nov 18, 2008 2:27 pm
Reply with quote

I have the LRECL as 2000 only for the out file, even though the output is of lenth 132chars. Is there any sysin commands which can increase the lenth to userdefined.
Back to top
View user's profile Send private message
Escapa

Senior Member


Joined: 16 Feb 2007
Posts: 1399
Location: IL, USA

PostPosted: Tue Nov 18, 2008 3:48 pm
Reply with quote

Most important questions arises is why you want to increase LRECL un-necessarily when it is managed with 133? It is mare wastage of space..
If you could explain your need of doing so then probably people here will be able to help you out better.
Back to top
View user's profile Send private message
Habeeb Shaik

New User


Joined: 29 Aug 2005
Posts: 10

PostPosted: Tue Nov 18, 2008 4:49 pm
Reply with quote

Let me be very clear. I have to compare two sequential files which is having records of length 2000. I want all the records from two files which are having the differences.

This is my requirement. Plz let me know if you want any more details.

Thanks,
Habeeb.
Back to top
View user's profile Send private message
Vijayakumar Mani

New User


Joined: 24 Oct 2007
Posts: 11
Location: Salem

PostPosted: Tue Nov 18, 2008 6:13 pm
Reply with quote

Hi Habeeb,
Out of the record length 2000, which field do you want to compare? I am giving here the code which compares entire record of length 2000.

You are saying that you need the records which are different. If so, i think you need the output by ommiting the records which are found in both the files.

If my understanding in correct, here is the SORT step which may help you (If only two files are to be compared).

Code:
//SORTIN    DD DSN=FILE1,DISP=SHR
//          DD DSN=FILE2,DISP=SHR
//SORTOUT   DD DSN=OUTFILE,DISP=SHR
//SYSIN     DD * 
INREC OVERLAY=(2001:C'00000001')                     
SORT FIELDS=(1,2000,CH,A)
SUM FIELDS=(2001,8,ZD)
OUTFIL FNAMES=SORTOUT,INCLUDE=(2001,8,ZD,EQ,1)
OUTREC=(1,2000)
/*
Back to top
View user's profile Send private message
Aaru

Senior Member


Joined: 03 Jul 2007
Posts: 1287
Location: Chennai, India

PostPosted: Tue Nov 18, 2008 6:37 pm
Reply with quote

Vijayakumar Mani,

I don't think this is an efficient way of doing this. I think you have too many control statements for a simple requiremt.

Habeeb,

Quote:
I have to compare two sequential files which is having records of length 2000. I want all the records from two files which are having the differences.


This can be done in a single SORT step. Mention u r requirement clearly and the key fields to compare.
Back to top
View user's profile Send private message
Arun Raj

Moderator


Joined: 17 Oct 2006
Posts: 2481
Location: @my desk

PostPosted: Tue Nov 18, 2008 7:41 pm
Reply with quote

Habeeb,

Do you have duplicate key records in input.
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Wed Nov 19, 2008 1:09 am
Reply with quote

Hello,

Quote:
The output should be of lenth 2000.
SUPERC will not show 2000 characters of comparison.
Back to top
View user's profile Send private message
darkstar13

New User


Joined: 06 Nov 2008
Posts: 46
Location: Manila, Philippines

PostPosted: Wed Nov 19, 2008 10:48 am
Reply with quote

I think the main problem is that SUPERC is not showing the difference for fields beyond column 133 (Am I right?). You can use the LONGLN parameter, however, it will only show the fields upto 176.

If you know which fields in your record that will show changes, then you can use CMPCOLMO/CMCOLMN (in SUPERCE panel, click on OPTIONS, then [1] for EDIT STATEMENTS):

Code:
  Menu  Utilities  Options  Help                 
                                                 
                   1  1. Edit Statements         
Command ===>          2. Process Options         
                      3. Profiles and Defaults   
New DS Name  . .                                 


However, if you don't know which fields will show error, I suggest you use COMPAREX, InSync or other compare utilities available at your shop.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> JCL & VSAM

 


Similar Topics
Topic Forum Replies
No new posts Compare 2 files(F1 & F2) and writ... JCL & VSAM 8
No new posts Store the data for fixed length COBOL Programming 1
No new posts How to split large record length file... DFSORT/ICETOOL 10
No new posts PARSE Syntax for not fix length word ... JCL & VSAM 7
No new posts SFTP Issue - destination file record ... All Other Mainframe Topics 2
Search our Forums:

Back to Top