MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Converting FB file to VBS file format

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Utilities
View previous topic :: View next topic  
Author Message
haqshaik
Beginner


Joined: 11 May 2005
Posts: 49
Topics: 19

PostPosted: Mon Jan 16, 2006 5:38 pm    Post subject: Converting FB file to VBS file format Reply with quote

Hi All,
Can we convert the FB file format to a VBS file format(Variable Block Spanned) using DFSORT or any other utility? I have used in past DFSORT to convert from FB to VB format.

Any thoughts will be hlpful.

Thanks,
Salauddin
Back to top
View user's profile Send private message
haqshaik
Beginner


Joined: 11 May 2005
Posts: 49
Topics: 19

PostPosted: Mon Jan 16, 2006 7:09 pm    Post subject: Reply with quote

Further adding to my post, I have a data in a Flat file of FB format. I need to load the data into a queue using CSQUTIL utility. This utility expects the data to be of VBS format and the rec length needs to be 32768.
I am trying to convert the file from FB to the VBS format with lrecl 32,768.
I am using outfil outrect option with FTOV. I am trying to specify the lrecl of 32,768 in the DCB parameter for the LRECL. But I am getting a message that I have crossed the max lenght.
If this is true, then a VBS file with lrecl of 32,768 can not be created by using either IEBGENER or IDCAMS.
I have tried out the outrec format option and made the lrecl equivalent to 32,768 by specifying the 31,976X and the rest is the data.
The DFOSRT job is abending.

I worte a COBOL program which puts a message into the queue. I copied the data from the queue into a file. The file created is of VBS and lrecl is 32,768. I have delted /flush out data from the queue. I have loaded the queue from the file created through the cobol program , using the CSQUTIL utility. This time, data has been loaded in the queue.
VBS file can be created by specifying the DCB parameters in the DFSORT Job. The files created through this which are not having a length of 32, 768, while using in CSQUTIL utility to load the data into the queue , the utility is abending.

Any thoughts would be helpful..

Thanks,
Salauddin
Back to top
View user's profile Send private message
Frank Yaeger
Sort Forum Moderator
Sort Forum Moderator


Joined: 02 Dec 2002
Posts: 1618
Topics: 31
Location: San Jose

PostPosted: Mon Jan 16, 2006 7:17 pm    Post subject: Reply with quote

DFSORT only supports an LRECL up to 32767 for VBS files, and cannot create an output file with an LRECL of 32768.
_________________
Frank Yaeger - DFSORT Development Team (IBM)
Specialties: JOINKEYS, FINDREP, WHEN=GROUP, ICETOOL, Symbols, Migration
DFSORT is on the Web at:
www.ibm.com/storage/dfsort
Back to top
View user's profile Send private message Send e-mail Visit poster's website
haqshaik
Beginner


Joined: 11 May 2005
Posts: 49
Topics: 19

PostPosted: Wed Jan 18, 2006 11:33 am    Post subject: Reply with quote

Frank,
Thanks for you reply. I was trying to create a VBS file of lrecl 32767.
Here are the messges in the sysout dd name.
Code:

ICE143I 0 BLOCKSET     COPY  TECHNIQUE SELECTED
ICE250I 0 VISIT http://www.ibm.com/storage/dfsort FOR DFSORT PAPERS, EXAMPLES AN
ICE000I 1 - CONTROL STATEMENTS FOR 5694-A01, Z/OS DFSORT V1R5 - 11:17 ON WED JAN
             SORT FIELDS=COPY
             OUTFIL OUTREC=(1:209,792,31975X),FTOV
                                                       $
ICE111A E REFORMATTING FIELD ERROR
ICE751I 0 C5-Q95214 C6-Q95214 C7-BASE   C8-Q95214 E7-Q95214
ICE052I 3 END OF DFSORT

Here is my Jcl.
 //S005  EXEC PGM=SORT
 //SORTIN DD DSN=INPUT FILE NAME,DISP=SHR
 //SORTOUT DD DSN=OUTPUT FILE,
 //           DISP=(NEW,CATLG,DELETE),
 //           DCB=(RECFM=VBS,BLKSIZE=0),
 //           SPACE=(TRK,(5,5),RLSE),
 //           UNIT=SYSDA
 //SYSOUT    DD SYSOUT=*
 //SYSIN DD *
    SORT FIELDS=COPY
    OUTFIL OUTREC=(1:209,792,31975X),FTOV
  /*
  //*

When I run the same Job, with the following control card
SORT FIELDS=COPY
OUTFIL OUTREC=(1:209,792,1000X),FTOV
the Job runs fine and OUTPUT FILE created with 1796 lrecl and VBS format.

Is there any limitation on the number of blanks or any other character used in the refomatting of a record, I guess probabaly I would be crossing such a limit. Correct me if I am wrong.

Is there in anything I am missing out in the first case?

Thanks for your help and time.

Thanks,
Salauddin
Back to top
View user's profile Send private message
Frank Yaeger
Sort Forum Moderator
Sort Forum Moderator


Joined: 02 Dec 2002
Posts: 1618
Topics: 31
Location: San Jose

PostPosted: Wed Jan 18, 2006 1:48 pm    Post subject: Reply with quote

Yes, there are limits. They are documented in "z/OS DFSORT Application Programming Guide" which you can access online from:

www.ibm.com/servers/storage/support/software/sort/mvs/srtmpub.html

The limit for n in nX is 4095. The limit for c in c: is 32752.

This will work, but do you really want every one of your output records to be 32767 bytes long? If not, you could add VLTRIM=X'40' to remove the trailing blanks.

Code:

   SORT FIELDS=COPY                         
   OUTFIL OUTREC=(1:209,792,32752:12X),FTOV

_________________
Frank Yaeger - DFSORT Development Team (IBM)
Specialties: JOINKEYS, FINDREP, WHEN=GROUP, ICETOOL, Symbols, Migration
DFSORT is on the Web at:
www.ibm.com/storage/dfsort


Last edited by Frank Yaeger on Wed Jan 18, 2006 1:52 pm; edited 2 times in total
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Bill Dennis
Advanced


Joined: 03 Dec 2002
Posts: 579
Topics: 1
Location: Iowa, USA

PostPosted: Wed Jan 18, 2006 1:49 pm    Post subject: Reply with quote

A queue can accept records of varying size. Why pad the record with blanks?
_________________
Regards,
Bill Dennis

Disclaimer: My comments on this foorum are my own and do not represent the opinions or suggestions of any other person or business entity.
Back to top
View user's profile Send private message
haqshaik
Beginner


Joined: 11 May 2005
Posts: 49
Topics: 19

PostPosted: Wed Jan 18, 2006 3:01 pm    Post subject: Reply with quote

Thanks Frank for your Reply.

Bill, As you said, a queue will accept message of any varying size, if you are writing it through the MQM API. if the queue needs to be loaded from a file it expects a file of VBS format and a record length of 32768, irrespective of the message size.
if the utility CSQUTIL run once to copy the messages from the queue , though the queue is empty, one record will be written to the output file. I am not sure what control information it will have. I am not able to download to a falt file to see the message.

I might as well wrong in making an assumption that if I could make a record of 32768, the message can be loaded into the queue, as the format is VBS. The last two bytes of RDW of VBS format keeps track of the start of the segment and end of the segment. It is hard to arrive at a relation between the number of records of length 32768 and the number of messages (Again varies wiht the size of the message).

I was thinking of loading the messages into queue with out using the MQM API's and using purly utilities, which gives out a flexibility of loading the queues in any environment. These are my thoughts and not neccessariliy be true. If am worng, Please correct me.

Once again Thanks to Frank and Bill.

Thanks,
Salauddin
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Utilities All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group