IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

How to map or use copybook without a fileaid?


IBM Mainframe Forums -> COBOL Programming
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
madlui56

New User


Joined: 08 Aug 2006
Posts: 61
Location: Philippines

PostPosted: Mon Jan 14, 2008 7:32 am
Reply with quote

I know F1 or F2(fileaid) in using copybook for mapping. Does anyone know way without using fileaid.. Right now we have copybooks but I don't know how to use it without even using fileaid for mapping...

Help Appreciated.

Thanks.

Louie
AIGSI - Malaysia
Back to top
View user's profile Send private message
murmohk1

Senior Member


Joined: 29 Jun 2006
Posts: 1436
Location: Bangalore,India

PostPosted: Mon Jan 14, 2008 8:07 am
Reply with quote

Louie,

Quote:
I know F1 or F2(fileaid) in using copybook for mapping


Quote:
I don't know how to use it without even using fileaid for mapping...

Dint get you? Could you explain bit clearly.
Back to top
View user's profile Send private message
madlui56

New User


Joined: 08 Aug 2006
Posts: 61
Location: Philippines

PostPosted: Mon Jan 14, 2008 8:18 am
Reply with quote

we don't have fileaid that I usually used in mapping dataset to its copybook. My new work doesnt have fileaid such as f1 or f2 command to use copybook in mapping. the problem besides fileaid whats the mainframe capability of mapping or using a copybook to map a specific dataset? thanks

Louie
AIGSI- Malaysia
Back to top
View user's profile Send private message
murmohk1

Senior Member


Joined: 29 Jun 2006
Posts: 1436
Location: Bangalore,India

PostPosted: Mon Jan 14, 2008 8:24 am
Reply with quote

Quote:
besides fileaid whats the mainframe capability of mapping or using a copybook to map a specific dataset?

We need a tool (like fileaid/filemaster) for mapping copybook with dataset. Without these, I dont think you can map.
Back to top
View user's profile Send private message
madlui56

New User


Joined: 08 Aug 2006
Posts: 61
Location: Philippines

PostPosted: Mon Jan 14, 2008 8:27 am
Reply with quote

How will I know If what tool do we possibly used in mapping a dataset with its copybook?
Thanks.
Back to top
View user's profile Send private message
Craq Giegerich

Senior Member


Joined: 19 May 2007
Posts: 1512
Location: Virginia, USA

PostPosted: Mon Jan 14, 2008 8:44 am
Reply with quote

madlui56 wrote:
How will I know If what tool do we possibly used in mapping a dataset with its copybook?
Thanks.


Try asking your coworkers?
Back to top
View user's profile Send private message
mmwife

Super Moderator


Joined: 30 May 2003
Posts: 1592

PostPosted: Mon Jan 14, 2008 9:28 am
Reply with quote

Most pgmrs have a little test pgm that they use to test functions they're not sure of. If you don't, make one and include a COPY stmt for the file layout in WS.

PS Just to be sure, write an 01 level item before the COPY stmt.
Back to top
View user's profile Send private message
murmohk1

Senior Member


Joined: 29 Jun 2006
Posts: 1436
Location: Bangalore,India

PostPosted: Mon Jan 14, 2008 9:32 am
Reply with quote

Jack,
How does your suggestion solve TS problem? If I understood OP well, he wanted to map a file with copybook (as we do in FILEAID) without using FILEAID or such tool.
Back to top
View user's profile Send private message
madlui56

New User


Joined: 08 Aug 2006
Posts: 61
Location: Philippines

PostPosted: Mon Jan 14, 2008 9:42 am
Reply with quote

Murali that's right..How can I do that?

Thanks.
Back to top
View user's profile Send private message
abhishekmdwivedi

New User


Joined: 22 Aug 2006
Posts: 95
Location: india

PostPosted: Mon Jan 14, 2008 12:21 pm
Reply with quote

Quote:

How does your suggestion solve TS problem? If I understood OP well, he wanted to map a file with copybook (as we do in FILEAID) without using FILEAID or such tool.


As jack suggested this is a pretty simple code.

Step 1 :
Put this in your working storage
Code:

copy your-copybook-name


Step 2 :
And then read the file your are having into the given working storage copybook.

Step 3 :
Put displays as :
Code:

Display "WS-FIELD1" : WS-FIELD1


This will show you the mapping of file records to its respective copybook.

Note : please make sure you include your copybook library(where the given copybook resides) in the SYSLIB before compiling the program.
Back to top
View user's profile Send private message
murmohk1

Senior Member


Joined: 29 Jun 2006
Posts: 1436
Location: Bangalore,India

PostPosted: Mon Jan 14, 2008 12:25 pm
Reply with quote

Abhishek,

If you few records, the trick suggested by Jack (and later explained in detailed by you) works well. Assuming you have 'n' million(s) of records..... then icon_cry.gif
Back to top
View user's profile Send private message
abhishekmdwivedi

New User


Joined: 22 Aug 2006
Posts: 95
Location: india

PostPosted: Mon Jan 14, 2008 12:30 pm
Reply with quote

Quote:

Assuming you have 'n' million(s) of records..... then


Well in that case just try to put formatted mapped output into a output file and try viewing it using 3.4 directly. I think this will be of no harm.
Back to top
View user's profile Send private message
madlui56

New User


Joined: 08 Aug 2006
Posts: 61
Location: Philippines

PostPosted: Mon Jan 14, 2008 1:58 pm
Reply with quote

How about if we have a variable length records?
Back to top
View user's profile Send private message
abhishekmdwivedi

New User


Joined: 22 Aug 2006
Posts: 95
Location: india

PostPosted: Mon Jan 14, 2008 2:04 pm
Reply with quote

Quote:
How about if we have a variable length records?


Will this have any affect on the given logic. I don't think so. As you already have a defined copybook for the file.
Back to top
View user's profile Send private message
mmwife

Super Moderator


Joined: 30 May 2003
Posts: 1592

PostPosted: Mon Jan 14, 2008 9:52 pm
Reply with quote

If you have a few million recs, nothing will help except your imagination.

FileAid takes a stab at a solution, but is fnctionally limited. 3.4 will run you into a region size problem.

IMAGINATION!!!
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


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

PostPosted: Tue Jan 15, 2008 2:50 am
Reply with quote

Hello,

If you have millions of records, they cannot be worked with easily (if at all) anyway.

I'd suggest creating a subset of a small number of records and continuing with the subset.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> COBOL Programming

 


Similar Topics
Topic Forum Replies
No new posts Search two or more word with FILEAID Compuware & Other Tools 15
No new posts REXX code to expand copybook in a cob... CLIST & REXX 2
No new posts Trying to change copybook in online c... CICS 4
No new posts Help to Filter File Manager Copybook ... DFSORT/ICETOOL 14
No new posts Generate output lines (SYSIN card for... DFSORT/ICETOOL 4
Search our Forums:

Back to Top