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
 

 

Conversion from FBA to FB
Goto page 1, 2, 3  Next
 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
Prasanya

New User


Joined: 04 Jun 2007
Posts: 34
Location: Chennai

PostPosted: Mon Feb 08, 2010 4:36 pm    Post subject: Conversion from FBA to FB
Reply with quote

Hi
I need to convert a FBA file to FB file. My FBA file is a log file. I have tried converting using synsort, IEBGENER and FILEAID but the target file is not having the same positions as in the input file.
Example, My input FBA file has the 3rd record from position 2 to 55 like,
NOTE: Running on IBM Model 2097 Serial Number 014A32,


But in my output file it is in the 2nd record itself from position 32 to 85 as
©NOTE: Running on IBM Model 2097 Serial Number 014A32

Please let me know how do i handle this without changing the positions except for the 1 byte for FBA
Back to top
View user's profile Send private message

expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Mon Feb 08, 2010 4:40 pm    Post subject:
Reply with quote

Unless you post the code and output from the batch job that you submit there is very little anyone can really do to help you.
Back to top
View user's profile Send private message
Prasanya

New User


Joined: 04 Jun 2007
Posts: 34
Location: Chennai

PostPosted: Mon Feb 08, 2010 4:53 pm    Post subject:
Reply with quote

My conversion code using IEBGENER is

Code:

//STEP01 EXEC PGM=IEBGENER                     
//SYSPRINT DD SYSOUT=*                         
//SYSUT1 DD DSN=AAAAA.MYWORKS.INPUT,DISP=SHR
//SYSUT2 DD DSN=AAAAA.MYWORKS.OUTPUT,     
//       DISP=(NEW,CATLG,DELETE),             
//       UNIT=SYSDA,                           
//       SPACE=(TRK,(1,5),RLSE),               
//       DCB=RECFM=FB                         
//SYSIN DD DUMMY                               


1st 4 records of input file

Code:

1                                                          The SAS System                            01:00 Tuesday, February 2, 2010
                                                                       
NOTE: Copyright (c) 2002-2003 by SAS Institute Inc., Cary, NC, USA.   
NOTE: SAS (r) 9.1 (TS1M3)   
                                           

The Output file is
Code:

 F    a11 ýThe SAS System Æ01:00 Tuesday, February 2, 2010Ì`ÌÚ BNOTE: Copyright (c) 2002-2003 by SAS Institute Inc., Cary, NC, USA.Ì[ qNOTE: SAS (r) 9.1 (TS1M3)ÌU
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Mon Feb 08, 2010 5:04 pm    Post subject:
Reply with quote

I think that using your SORT product would be easiest
Back to top
View user's profile Send private message
Prasanya

New User


Joined: 04 Jun 2007
Posts: 34
Location: Chennai

PostPosted: Mon Feb 08, 2010 5:32 pm    Post subject:
Reply with quote

i got the same out put when i used the following job

Code:

//STEP02 EXEC PGM=SYNCSORT                                       
//SORTIN DD DSN=AAAAA.MYWORKS.INPUT,DISP=SHR                   
//SORTOUT DD DSN=AAAAA.MYWORKS.OUTPUT,                       
//       DISP=(NEW,CATLG,DELETE),RECFM=FB,SPACE=(CYL,(10,10),RLSE)
//SYSOUT DD SYSOUT=*                                             
//SYSIN DD *                                                     
     SORT FIELDS=COPY                                             
     OUTREC FIELDS=(1:2,254,1X)                                   
/*                                                               


Please let me know if there is any other way to do this
Back to top
View user's profile Send private message
PeterHolland

Global Moderator


Joined: 27 Oct 2009
Posts: 2422
Location: Netherlands, Amstelveen

PostPosted: Mon Feb 08, 2010 5:33 pm    Post subject:
Reply with quote

Why would someone want to reformat SAS log output?

And if there is a SAS log, i guess SAS is installed.
So use SAS to get rid of the print control character.
Back to top
View user's profile Send private message
Prasanya

New User


Joined: 04 Jun 2007
Posts: 34
Location: Chennai

PostPosted: Mon Feb 08, 2010 5:38 pm    Post subject:
Reply with quote

Can you please tell me how to do it with SAS?
I need to validate some data and thats why i need the positions.
Back to top
View user's profile Send private message
Prasanya

New User


Joined: 04 Jun 2007
Posts: 34
Location: Chennai

PostPosted: Mon Feb 08, 2010 5:44 pm    Post subject:
Reply with quote

Isn't there a way to do this using SORT?
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Mon Feb 08, 2010 5:45 pm    Post subject:
Reply with quote

What are the file attributes for the input, and what do you want them to be for the output.
Back to top
View user's profile Send private message
Prasanya

New User


Joined: 04 Jun 2007
Posts: 34
Location: Chennai

PostPosted: Mon Feb 08, 2010 5:47 pm    Post subject:
Reply with quote

File attributes for Input file:
Organization . . . : PS
Record format . . . : FBA
Record length . . . : 255
Block size . . . . : 27795

File attributes for Output file:
Organization . . . : PS
Record format . . . : FB
Record length . . . : 254
Block size . . . . : 25400
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Mon Feb 08, 2010 6:39 pm    Post subject:
Reply with quote

/Good mood ON

I use DFSORT here, but for such a simple task as this I can not see that the control statements would vary very much, if at all, but if they do I'm sure that one of the SYNCSORT users / support will be better able to help you.

Code:
//SORTSTEP EXEC PGM=SORT
//SYSOUT   DD SYSOUT=*
//SORTIN   DD DSN=Input dataset name,DISP=SHR
//SORTOUT  DD DSN=Output dataset name,DISP=(,CATLG,DELETE),
//            SPACE=( ),RECFM=FB,LRECL=255
//SYSIN    DD *
 OPTION COPY
 OUTFIL OUTREC=(2,254,1X)
/*

Although, I can't really see the difference between processing a FB file or an FBA file.

/Good mood OFF
Back to top
View user's profile Send private message
dick scherrer

Site Director


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

PostPosted: Mon Feb 08, 2010 8:42 pm    Post subject:
Reply with quote

Hello,

I also wonder about the need to make an entire copy of the file when all of the needed data is in the original?

Is there some reason to not process the existing file?
Back to top
View user's profile Send private message
Prasanya

New User


Joined: 04 Jun 2007
Posts: 34
Location: Chennai

PostPosted: Tue Feb 09, 2010 11:48 am    Post subject:
Reply with quote

While processing the existing file, am having mismatch in the positions that i give in my sort control cards.. Please help me with this. I need to check for the presence of certain data in the existing file.
Back to top
View user's profile Send private message
Arun Raj

Moderator


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

PostPosted: Tue Feb 09, 2010 12:10 pm    Post subject:
Reply with quote

Quote:
I need to check for the presence of certain data in the existing file.
AFAIK You can very well do this without converting it to FB. As suggested above process the existing FBA file. What do you mean by "mismatch" here?
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10201
Location: italy

PostPosted: Tue Feb 09, 2010 12:17 pm    Post subject: Reply to: Conversion from FBA to FB
Reply with quote

You have not explained yet what You want to achieve,
clarity when asking for help is a prerequisite for good answers...

You posted two files samples...
the first one is, looks like, a sysout/sysprint dataset

the second one even if contains the same info, is formatted in some SASish way
and does not look at all like a FBsomething dataset, more likely like a variable length one.

so, please explain again, in a better way what You want to do,
and no confusion in the file description please.

if You simply want to process the sysprint file, why post the misleading output file ???
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Tue Feb 09, 2010 12:23 pm    Post subject:
Reply with quote

Prasanya wrote:
While processing the existing file, am having mismatch in the positions that i give in my sort control cards.. Please help me with this. I need to check for the presence of certain data in the existing file.

Unless you learn, and very quickly, that when you bother to post usefull information you may receive a usefull answer.
Back to top
View user's profile Send private message
Prasanya

New User


Joined: 04 Jun 2007
Posts: 34
Location: Chennai

PostPosted: Tue Feb 09, 2010 1:28 pm    Post subject:
Reply with quote

My input file is a SAS log file from a production system. I need to validate the messages and errors in it using a job since i get 22 such files a day.
When i tried checking for the errors and messages using the positions that i found in the log file - they dint match. Thats why i thought it would be better to convert the log file to a FB file.
Please suggest if there is any appropriate way to validate the errors and messages present in the log file
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10201
Location: italy

PostPosted: Tue Feb 09, 2010 1:46 pm    Post subject: Reply to: Conversion from FBA to FB
Reply with quote

please reread my previous post !
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1703
Location: Australia

PostPosted: Tue Feb 09, 2010 1:52 pm    Post subject:
Reply with quote

Hi,

the data is from DDNAME SASLOG and is a VB file with an LRECL of 137.

How is the dataset created ? ie. What does the JCL for //SASLOG DD look like ?

Gerry
Back to top
View user's profile Send private message
William Thompson

Global Moderator


Joined: 18 Nov 2006
Posts: 3158
Location: Tucson AZ

PostPosted: Tue Feb 09, 2010 2:03 pm    Post subject:
Reply with quote

Prasanya wrote:
When i tried checking for the errors and messages using the positions that i found in the log file - they dint match. Thats why i thought it would be better to convert the log file to a FB file.
Why not just add one to 'the position' to allow for the 'I/O command code'?
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 -> JCL & VSAM All times are GMT + 6 Hours
Goto page 1, 2, 3  Next
Page 1 of 3

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts File Aid to File Manager conversion murali3955 IBM Tools 4 Thu Nov 24, 2016 3:41 pm
No new posts Conversion of a VB file to FB. isssal DFSORT/ICETOOL 1 Mon Oct 31, 2016 10:23 pm
No new posts EBCDIC to ASCII conversion using OCOPY mistah kurtz All Other Mainframe Topics 5 Tue Sep 06, 2016 2:26 pm
No new posts Comparex utility to Syncsort conversion mistah kurtz SYNCSORT 11 Fri Jul 22, 2016 1:53 pm
No new posts changing z/os unicode conversion service meykh2014 All Other Mainframe Topics 0 Tue Jul 12, 2016 10:49 am


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