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
 

 

NDM a variable block file

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> IBM Tools
View previous topic :: :: View next topic  
Author Message
spoorni

New User


Joined: 29 Nov 2007
Posts: 20
Location: india

PostPosted: Wed Dec 23, 2015 6:08 am    Post subject: NDM a variable block file
Reply with quote

Hi,

I am trying to NDM a VSAM file with a variable block to a unix server. Once I NDM the file, the NDM process is successful but when i try to read the file on the UNIX server, i am unable to do that and my script fails. Is it possible to NDM a VSAM variable block file to UNIX? If yes, would the length of the file be the same as that of the VSAM file or do I need to copy it to a flat file with a length of file as length plus 4 bytes?
Anyone face the same issue?
Back to top
View user's profile Send private message

Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 7914
Location: Bellevue, IA

PostPosted: Wed Dec 23, 2015 9:25 am    Post subject:
Reply with quote

Quote:
Is it possible to NDM a VSAM variable block file to UNIX?
Yes - you are doing it! A much more interesting and informative question -- Is the resulting file going to be usable on the Unix server? Probably not. VSAM has control information embedded that is binary data and when the VSAM data set is transferred, the control information will be converted to ASCII and hence lose every bit of meaning it had. If, on the other hand, you do NOT convert to ASCII then you're stuck with an EBCDIC file on the Unix Server which won't be very readable either. I suspect NDM with VSAM data sets is designed to go z/OS to z/OS and not z/OS to Unix -- so the VSAM control data is most likely being transferred with the application data. Hence unless you're pretty good at translating hex (that went through an ASCII conversion process) RBA data into something Unix recognizes, the transferred file is most likely useless.

Why don't you do the normal thing and unload the VSAM data set into a sequential variable length data set (with no binary or packed decimal fields) and NDM the sequential data set to the Unix server? This is what you should be doing. Because even if you get the VSAM data set on a Unix server with valid control data, Unix servers do not deal with VSAM data sets and hence you've got an unusable file on the Unix server, and there's no way that I am aware of to make it usable.
Back to top
View user's profile Send private message
vasanthz

Global Moderator


Joined: 28 Aug 2007
Posts: 1445
Location: Azeroth

PostPosted: Wed Dec 23, 2015 3:56 pm    Post subject:
Reply with quote

Hello Robert,
Just curious, if we send a variable block file to unix server, would unix server be able to interpret the RDW properly?

Or does NDM does the RDW interpretation and sends a fixed block record to unix?
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 7914
Location: Bellevue, IA

PostPosted: Wed Dec 23, 2015 6:49 pm    Post subject:
Reply with quote

If NDM is doing EBCDIC to ASCII translation, I would expect the RDW to be removed and a LF (since the data is going to a Unix machine and not a Windows machine) added to the end of the record (which is what FTP does for a text transfer). If NDM is doing a binary transmission then the RDW will (usually) be transferred as part of the record and Unix won't know what to do with it since it's 4 bytes of hexadecimal stuck on the front of each record (and another 4 bytes stuck to the front of each block). And without the line terminators Unix won't know where one record ends and the next begins so it'll treat the entire data set as a single record.

I don't know a whole lot about NDM since it's been a number of years since I used CONNECT:DIRECT, but I don't recall any option to convert a variable length record into a fixed length (but NDM may have that capability now).
Back to top
View user's profile Send private message
steve-myers

Active User


Joined: 30 Nov 2013
Posts: 462
Location: The Universe

PostPosted: Wed Dec 23, 2015 7:55 pm    Post subject:
Reply with quote

Vasanth - I know nothing about NDM, but ...

No data mover I know of sends RDW data in a "binary" data transmission, though I believe recent versions of IBM FTP have an option to send RDW data. The traditional rule is control data (e.g., RDW data) is not sent in "binary" data.

In any event, VSAM data records do not have RDW type data. Length data for records in VSAM data sets is external to the data. Programs that read VSAM data sets normally retrieve record length data from the RPL. A VSAM RPL is a data area that contains the address of the data area where VSAM is to move the data to, as well as the length of the data area and the length of the data moved to the data area.

In any event, this may not be an issue. The TS claims the data set has fixed length records. If the receiving system cannot deblock this data it is a failure of the program on the receiving system, not a failure on the part of the data mover. Of course, the TS may be lying, or at best, his information is incorrect.

The TS did not bother to tell us if the data was sent as "binary" data or "text" data. Data movers insert *nix "new line" characters after each logical record when the data is sent as text data.
Back to top
View user's profile Send private message
vasanthz

Global Moderator


Joined: 28 Aug 2007
Posts: 1445
Location: Azeroth

PostPosted: Thu Dec 24, 2015 7:59 pm    Post subject:
Reply with quote

Thank you Robert and Steve for your thoughts.

Regards,
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 -> IBM Tools All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Add PD field from 2nd file to PD in 1st Sushant Garje DFSORT/ICETOOL 6 Thu Dec 01, 2016 4:32 pm
No new posts File Aid to File Manager conversion murali3955 IBM Tools 4 Thu Nov 24, 2016 3:41 pm
No new posts How to convert the VBM file to VB or... Sulabh Agrawal JCL & VSAM 4 Fri Nov 18, 2016 1:04 pm
No new posts CICS Roll back partially - Need to re... dwijadas CICS 4 Wed Nov 16, 2016 4:30 pm
No new posts Problem in writing Output file vickey_dw COBOL Programming 5 Mon Nov 14, 2016 11:14 pm


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