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
 

 

File compare easytrieve

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CA Products
View previous topic :: :: View next topic  
Author Message
Mathiv Anan

Active User


Joined: 23 Jul 2008
Posts: 106
Location: USA

PostPosted: Mon Apr 27, 2009 5:17 pm    Post subject: File compare easytrieve
Reply with quote

Hi,

I am trying to compare two files say, F1 and F2 and writing it to an output file say F3 based on a matching KEY field of 9 bytes. (using easytrieve plus)

F1 and F2 are VB files with LRECL = 8364 bytes and sorted based on key field.

F1 and F2 have record length of 3320 only though their LRECL is 8364 bytes.

Hence output record should also have record length of 3320 bytes with the file LRECL as 8364 bytes.

But actually records in output file is having largest length i.e 8364 bytes though input file is having record length of 3320 bytes.
i.e after 3320, low-values are populated.

This is creating problem in downstream as I need to have records of 3320 bytes only.

is there any way we can calculate length of each record before writing the output file?

Please let me know if my question is not very clear.
Back to top
View user's profile Send private message

enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10256
Location: italy

PostPosted: Mon Apr 27, 2009 5:22 pm    Post subject: Reply to: File compare easytrieve
Reply with quote

review Your understanding of the DCB attributes...

For VB datasets ( variable blocked ) the lrecl specified in the dcb has nothing(almost)
to do with the length of individual records
it is the longest length to expected,
if the program is well written You will get records of the right length even if
the dcb info specifies a bigger one
( always wise to do it )

not thread related
I wonder why on these forums there are so many VB datasets when
from the discussion comes out that the records are really fixed length icon_confused.gif
Back to top
View user's profile Send private message
Mathiv Anan

Active User


Joined: 23 Jul 2008
Posts: 106
Location: USA

PostPosted: Mon Apr 27, 2009 5:24 pm    Post subject:
Reply with quote

ok. thx
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10256
Location: italy

PostPosted: Mon Apr 27, 2009 5:36 pm    Post subject: Reply to: File compare easytrieve
Reply with quote

Quote:
... after 3320, low-values are populated.


I had not seen the quote,
but as a general point in any decently written program / jcl two things
should be carried along...

the DCB info ( as I said before irrelevant as far as the single record content/layout)

as in this case the unaltered single record length/content/layout

if the record length gets changed to the maximum record length
and the unused area filled with low values

there is certainly a flaw in the application processing
or processing parameters
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8055
Location: East Dubuque, Illinois, USA

PostPosted: Mon Apr 27, 2009 5:37 pm    Post subject:
Reply with quote

Quote:
not thread related
I wonder why on these forums there are so many VB datasets when
from the discussion comes out that the records are really fixed length
My guess is the system designers think it provides flexibility by not tying the design to one fixed record length. Of course if nobody supporting the system understands the VB file, I'm not sure there's enough gained to make it worthwhile.
Back to top
View user's profile Send private message
Mathiv Anan

Active User


Joined: 23 Jul 2008
Posts: 106
Location: USA

PostPosted: Tue May 05, 2009 5:45 pm    Post subject: Reply to: File compare easytrieve
Reply with quote

Hi Robert/enrico

I added below statements in the program and it is working fine.

Code:
FILEB:RECORD-LENGTH = FILEA:RECORD-LENGTH
         PUT FILEB FROM FILEA


FILEA -> Input file
FILEB -> Output file

Thanks
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 -> CA Products All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Converting Variable block file to Fix... bhavana yalavarthi DFSORT/ICETOOL 10 Tue May 16, 2017 2:20 pm
No new posts member list compare jzhardy TSO/ISPF 6 Fri May 12, 2017 3:18 pm
No new posts Getting error while opening a variabl... apandey1 COBOL Programming 5 Fri May 05, 2017 12:22 pm
No new posts Issue with NDM process to transmit ES... chetanambi All Other Mainframe Topics 6 Wed May 03, 2017 10:52 am
No new posts READ A PACKED "NEGATIVE" FI... jdesouza CA Products 3 Tue May 02, 2017 11:43 pm


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