View previous topic :: View next topic |
Author |
Message |
senthilvel Beginner
Joined: 04 Feb 2003 Posts: 3 Topics: 2 Location: India
|
Posted: Wed Feb 05, 2003 1:25 am Post subject: FB to VB |
|
|
Hi,
I need to copy the contents of a FB file to VB file at run time using JCL
Can this be done using syncsort utility?
Thanks in Advance,
E.senthilvel |
|
Back to top |
|
 |
Premkumar Moderator

Joined: 28 Nov 2002 Posts: 77 Topics: 7 Location: Chennai, India
|
|
Back to top |
|
 |
kolusu Site Admin

Joined: 26 Nov 2002 Posts: 12382 Topics: 75 Location: San Jose
|
Posted: Wed Feb 05, 2003 5:12 pm Post subject: |
|
|
Senthilvel,
Syncsort utility does not have any built in feature to create a variable block file from a fixed block file.As premkumar mentioned, it is new feature available with DFSORT.if you don't have DFSORT at your shop then you can use IDCAMS, IEBGENER,File-aid,SAS,easytrieve to create a variable blocked file.
IDCAMS example:
Code: |
//STEP0100 EXEC PGM=IDCAMS
//*
//SYSPRINT DD SYSOUT=*
//IN DD DSN=YOUR FB INPUT FILE,
// DISP=SHR
//OUT DD DSN=YOUR VB OUTPUT FILE,
// DISP=(NEW,CATLG,DELETE),
// UNIT=SYSDA,
// SPACE=(CYL,(X,Y),RLSE),
// LRECL=ZZZ,RECFM=VB
//SYSIN DD *
REPRO IFILE(IN) OFILE(OUT)
/*
|
IEBGENER example:
Code: |
//STEP0200 EXEC PGM=IEBGENER
//*
//SYSPRINT DD SYSOUT=*
//SYSUT1 DD DSN=YOUR INPUT FB FILE,
// DISP=SHR
//SYSUT2 DD DSN=YOUR OUTPUT VB FILE,
// DISP=(NEW,CATLG,DELETE),
// UNIT=SYSDA,
// SPACE=(CYL,(X,Y),RLSE),
// LRECL=ZZZ,RECFM=VB
//SYSIN DD DUMMY
/*
|
SAS example:
Code: |
Data _NULL_ ;
Infile FBFile ;
Input ;
File VBFile ;
Put_Infile_;
|
Hope this helps...
cheers
kolusu |
|
Back to top |
|
 |
Hariharan78 Beginner

Joined: 01 Dec 2002 Posts: 28 Topics: 8 Location: India
|
Posted: Thu Feb 06, 2003 2:02 am Post subject: |
|
|
Hi,
I think there Convert available that can used in Sysin.
I think the syntax is convert=VB -- To convert the input file to VB
Please check.
Have a nice day
Bye _________________ S.Hariharan |
|
Back to top |
|
 |
kolusu Site Admin

Joined: 26 Nov 2002 Posts: 12382 Topics: 75 Location: San Jose
|
Posted: Thu Feb 06, 2003 7:16 am Post subject: |
|
|
Hariharan,
CONVERT option is to convert a VB to FB format.Syncsort does not support the reverse conversion .ie. FB TO VB
Kolusu |
|
Back to top |
|
 |
Frank Yaeger Sort Forum Moderator

Joined: 02 Dec 2002 Posts: 1618 Topics: 31 Location: San Jose
|
Posted: Thu Feb 06, 2003 11:40 am Post subject: |
|
|
Note that with DFSORT, you can use VTOF (or CONVERT) to go from VB to FB, and FTOV to go from FB to VB. It's a lot easier to remember what FTOV and VTOF do then what CONVERT does. _________________ 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 |
|
 |
ranga_subham Intermediate

Joined: 31 Jan 2006 Posts: 255 Topics: 72
|
Posted: Sat Apr 08, 2006 1:37 am Post subject: using Syncsort to convert FB to VB. |
|
|
Kolusu,
Can I use SYNCSORT also to convert FB to VB. I mean SORT FIELDS=COPY option. Because, IDCAMS / IEBGENER are just copying the infile to outfile in the examples !!!
Code: |
//STEP0100 EXEC PGM=SYNCSORT
//*
//SYSOUT DD SYSOUT=*
//SYSPRINT DD SYSOUT=*
//SORTIN DD DSN=YOUR FB INPUT FILE,
// DISP=SHR
//SORTOUT DD DSN=YOUR VB OUTPUT FILE,
// DISP=(NEW,CATLG,DELETE),
// UNIT=SYSDA,
// SPACE=(CYL,(X,Y),RLSE),
// LRECL=ZZZ,RECFM=VB
//SYSIN DD *
SORT FIELDS=COPY
/*
|
Please correct me if I am wrong. _________________ Ranga
*****
None of us is as smart as all of us - Ken Blanchard |
|
Back to top |
|
 |
ranga_subham Intermediate

Joined: 31 Jan 2006 Posts: 255 Topics: 72
|
Posted: Sat Apr 08, 2006 1:48 am Post subject: SYNCSORT failed. |
|
|
Kolusu,
I got the following messages in SYSOUT when tried to copy a FB to VB using SYNCSORT. It was a failure to copy FB to VB using SYNCSORT.........
Code: |
SYNCSORT FOR Z/OS 1.2.0.0R
WER108I SORTIN : RECFM=FB ; LRECL= 60; BLKSIZE= 6000
WER202A SORTOUT RECFM INCOMPATIBLE
WER110I SORTOUT : RECFM=VB ; LRECL= ; BLKSIZE=
WER462I OUTPUT LRECL DIFFERS FROM SORTOUT LRECL
WER449I SYNCSORT GLOBAL DSM SUBSYSTEM ACTIVE
|
Still wondering why such a restriction to copy a file!!?? _________________ Ranga
*****
None of us is as smart as all of us - Ken Blanchard |
|
Back to top |
|
 |
ranga_subham Intermediate

Joined: 31 Jan 2006 Posts: 255 Topics: 72
|
Posted: Sat Apr 08, 2006 2:13 am Post subject: Why the RDW is not listed in the SYSOUT?? |
|
|
Hi Kolusu,
I ran the following job to convert a FB to VB.
Code: |
//STEP0100 EXEC PGM=IEBGENER
//*
//SYSPRINT DD SYSOUT=*
//SYSUT1 DD DSN=XXXXXX.INPUT.FB,
// DISP=SHR
//SYSUT2 DD DSN=XXXXXX.OUTPUT.VB,
// DISP=(NEW,CATLG,DELETE),
// UNIT=SYSDA,
// SPACE=(TRK,(1,1),RLSE),
// DCB=(LRECL=064,RECFM=VB,BLKSIZE=00000)
//SYSIN DD DUMMY
/*
|
Then I ran the following job to see RDW in the spool.....
Code: |
//STEP0200 EXEC PGM=FILEAID
//*
//SYSPRINT DD SYSOUT=*
//SYSIN DD *
$$DD01 LIST RDW=0
/*
//DD01 DD DSN=XXXXXX.OUTPUT.VB,DISP=SHR
//
|
The job ended successfully. But I found nothing in the spool !!??
Any help please? _________________ Ranga
*****
None of us is as smart as all of us - Ken Blanchard |
|
Back to top |
|
 |
kolusu Site Admin

Joined: 26 Nov 2002 Posts: 12382 Topics: 75 Location: San Jose
|
Posted: Sat Apr 08, 2006 8:11 am Post subject: |
|
|
Quote: |
SYNCSORT FOR Z/OS 1.2.0.0R
WER108I SORTIN : RECFM=FB ; LRECL= 60; BLKSIZE= 6000
WER202A SORTOUT RECFM INCOMPATIBLE
WER110I SORTOUT : RECFM=VB ; LRECL= ; BLKSIZE=
WER462I OUTPUT LRECL DIFFERS FROM SORTOUT LRECL
WER449I SYNCSORT GLOBAL DSM SUBSYSTEM ACTIVE
|
ranga_subham,
Yes with synsort you can convert a FB file to an VB file. You forgot to add the Parm (FTOV) to convert the FB file to VB file.Your control cards should be
Code: |
SORT FIELDS=COPY
OUTFIL FTOV
|
Always remember that VB file LRECL is 4 bytes(RDW) more than FB file.
Remember that with SORT you never have to code the DCB parameter , they will be automatically calculated by sort based on the input dataset and control card statement. So I suggest that you remove the DCB statement in your sort and re-run the job.
Coming to your Fileaid job. List parameter puts the listing in SYSLIST DD statement which is missing in your JCL. Add that statement and look at the output in the SYSLIST.
Hope this helps...
Cheers
Kolusu _________________ Kolusu
www.linkedin.com/in/kolusu |
|
Back to top |
|
 |
Phantom Data Mgmt Moderator

Joined: 07 Jan 2003 Posts: 1056 Topics: 91 Location: The Blue Planet
|
Posted: Mon Apr 10, 2006 12:15 am Post subject: |
|
|
I would just like to add one more point here.
The option to convert FB to VB is available only with the latest versions of Syncsort (Ver 1.1 and above). Note that older versions (Syncsort v 3.6 and 3.7) does not have this capability. (I don't understand the version naming convention here !!!).
I got totally confused when I read this thread today morning from the top. Later I realized that the first few posts were actually posted sometime in 2003.
Thanks,
Phantom |
|
Back to top |
|
 |
ranga_subham Intermediate

Joined: 31 Jan 2006 Posts: 255 Topics: 72
|
Posted: Tue Apr 11, 2006 10:10 pm Post subject: Thanks. |
|
|
Kolusu,
Thanks for the suggestion. I ran it today and it ended successfully.
Quote: |
Remember that with SORT you never have to code the DCB parameter , they will be automatically calculated by sort based on the input dataset and control card statement.
|
The above is a very very valid information which I did not know before. That is really a good piece of information. Thanks a lot.
Phantom,
I have been reading the posts including everything to know / learn several new things like the one mentioned above. So, I have been digging this forum a lot to digest the things...............  _________________ Ranga
*****
None of us is as smart as all of us - Ken Blanchard |
|
Back to top |
|
 |
ranga_subham Intermediate

Joined: 31 Jan 2006 Posts: 255 Topics: 72
|
Posted: Tue Apr 11, 2006 10:20 pm Post subject: SYSLIST entries. |
|
|
Kolusu,
Quote: |
Coming to your Fileaid job. List parameter puts the listing in SYSLIST DD statement which is missing in your JCL. Add that statement and look at the output in the SYSLIST.
|
The following is what shown in the SYSLIST.
Code: |
F I L E - A I D V8.8.0 11 - APR - 2006 23.13.04 PAGE 1
DD01=XXXXXX.OUTPUT.VB VOL=XXX140
AFSDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDAAAAAAAAAAA
AAAAAAAAADBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB
AFSDDDDDDDDDDDDDDDDDDDDDDCCCCCCCCCCCCCCCCCCCCCC
|
Except this, I don't see any other info. Do I need to put on "HEX ON" command to find out the things? Please let me know.
Thanks. _________________ Ranga
*****
None of us is as smart as all of us - Ken Blanchard |
|
Back to top |
|
 |
kolusu Site Admin

Joined: 26 Nov 2002 Posts: 12382 Topics: 75 Location: San Jose
|
Posted: Wed Apr 12, 2006 4:32 am Post subject: |
|
|
Quote: |
Except this, I don't see any other info. Do I need to put on "HEX ON" command to find out the things? Please let me know
|
ranga_subham,
I am not sure as what you are expecting from the list function.
The LIST function prints alphanumeric input data only and does not show record number or any other record information. The LIST function prints packed and binary data as blanks. Because File-AID lists 100 bytes of data per line, LIST displays records larger than 100 bytes on multiple lines.
What did you expect that you will see?
Hope this helps...
Cheers
Kolusu _________________ Kolusu
www.linkedin.com/in/kolusu |
|
Back to top |
|
 |
ranga_subham Intermediate

Joined: 31 Jan 2006 Posts: 255 Topics: 72
|
Posted: Wed Apr 12, 2006 4:39 am Post subject: |
|
|
Oh...Ok. I was trying to find out RDW of each record. I thought it will display RDW of all records because we specified RDW=0. I was misled by the RDW function. I read it somewhere in this forum only to see the RDW of each and every VB record. That was posted by Frank of IBM I presume.
Anyway, the list also seems to be very useful function to display data.
Thank you. _________________ Ranga
*****
None of us is as smart as all of us - Ken Blanchard |
|
Back to top |
|
 |
|
|