View previous topic :: View next topic
|
Author |
Message |
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hi Jasorn,
Cool
Quote: |
I was planning to use the cobol 2 eztrieve converter that comes with eztrieve somehow but never could get that to work well with redefines and occurs |
If you are still interested in generating Easytrieve layouts from a cobol copybook, post something in the CA part of the forum. I've recently generated some for a client.
d |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
Quote: |
does that mean the one that comes with eztrieve is ;broken' and it's not just me? |
Easytrieve wasn't "broken" but it did take a bit of "fiddling around" - all i did was work with the easytrieve macros to see what they were doing/expecting and the set up my jobs so they conformed. My biggest hurdle was realizing that the CBLCNVRT process is cobol compiler dependent. . . |
|
Back to top |
|
|
jasorn Warnings : 1 Active User
Joined: 12 Jul 2006 Posts: 191 Location: USA
|
|
|
|
dick scherrer wrote: |
Easytrieve wasn't "broken" but it did take a bit of "fiddling around" - all i did was work with the easytrieve macros to see what they were doing/expecting and the set up my jobs so they conformed. My biggest hurdle was realizing that the CBLCNVRT process is cobol compiler dependent. . . |
Yeah. I did get it to work but the problem is I've never gotten it to handle occurs clauses or redefines. Does CBLCNVRT handles those and I was just to dumb to figure it out?
Also there's currently an implementation of CBLCNVRT someone at my company put together. It's a screen you pass it the copybook name and it uses CBLCNVRT to create the eztrieve. It has the same issue I always had: give it some occurs and redefines and it pukes. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hi Jasorn,
Quote: |
Does CBLCNVRT handles those and I was just to dumb to figure it out? |
I suspect it wasn't you Over time there have been bugs fixed. A problem i had once upon a time was that any numeric definition was converted to alpha.
I did create one today that has occurs, redefines and at least one odo just for testing this. It also has binary, packed-decimal and zoned-decimal fields in additon to pic x fields.
If you can send me a PM with a problem cobol definition as a .txt attachment, i'll see if i can generate good easytrieve or if it has a problem. |
|
Back to top |
|
|
Debabrata Pruseth
New User
Joined: 11 Dec 2008 Posts: 59 Location: Pune , India
|
|
|
|
Hi
I too have a tool to convert COBOL layout to EZT MACRO . First we convert the COBOL layout to FILEAID layout through batch JCL and in the next STEP use a REXX to read the FILEAID layout and make a new EZT macro from it . For OCCURS it appends number in ascending order for the variable in the macro . Like
Code: |
03 :AMBS:-WAIVE-SVC-CHG OCCURS 10 TIMES
INDEXED BY X-:AMBS:-WSC
PIC 9. |
is converted to
Code: |
AMBS-WAIVE-SVC-CHG-1
AMBS-WAIVE-SVC-CHG-2
AMBS-WAIVE-SVC-CHG-3
AMBS-WAIVE-SVC-CHG-4
AMBS-WAIVE-SVC-CHG-5
AMBS-WAIVE-SVC-CHG-6
AMBS-WAIVE-SVC-CHG-7
AMBS-WAIVE-SVC-CHG-8
AMBS-WAIVE-SVC-CHG-9
AMBS-WAIVE-SVC-CHG-10 |
in the macro. There is one issue , for a binary variable , the macro variable is packed . This is because in the intermediate fileaid layout , you cannot distinguish between a binary variable and comp variable.
I was just enquiring weather you are using a similar approach or different one . If you can let me know the STEPS of approach it will help us improve upon the tool . We don't use CBLCNVRT. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
If you have Easytrieve, i suggest you try CBLCNVRT.
I don't understand why an array is changed to individually named fields This might make some trivial bit of code "grow" to where it might become unmanagable?
With CBLCNVRT cobol arrays become easytrieve arrays. |
|
Back to top |
|
|
Douglas Wilder
Active User
Joined: 28 Nov 2006 Posts: 305 Location: Deerfield IL
|
|
|
|
When using CBLCNVRT you run a COBOL compile of a stub module with the copybook. Then read the compile listing into the Easytrieve program. |
|
Back to top |
|
|
Douglas Wilder
Active User
Joined: 28 Nov 2006 Posts: 305 Location: Deerfield IL
|
|
|
|
The "array is changed to individually named fields" probably because that is the way the FileAid "View Record Layout" works. |
|
Back to top |
|
|
Debabrata Pruseth
New User
Joined: 11 Dec 2008 Posts: 59 Location: Pune , India
|
|
|
|
Yes Douglas , in the fileaid the above fields are converted to
Code: |
3 :AMBS:-WAIVE-SVC-CHG(1)
3 :AMBS:-WAIVE-SVC-CHG(2)
3 :AMBS:-WAIVE-SVC-CHG(3)
3 :AMBS:-WAIVE-SVC-CHG(4)
3 :AMBS:-WAIVE-SVC-CHG(5)
3 :AMBS:-WAIVE-SVC-CHG(6)
3 :AMBS:-WAIVE-SVC-CHG(7)
3 :AMBS:-WAIVE-SVC-CHG(8)
3 :AMBS:-WAIVE-SVC-CHG(9)
3 :AMBS:-WAIVE-SVC-CHG(10) |
hence in the final macro also we have a similar format , as it's easier and less complicated to process into.
However some issue like the binary field one , mentioned earlier , still remains. For other practical purpose it works fine and i think those who do not use CBLCNVRT can use this logic effectively.
I was not aware of the utility CBLCNVRT . But i checked our system and we are using 'CA-EASYTRIEVE PLUS-6.4 0311' so i think this utility will be there also here. I searched this forum and found that you have posted some material regarding how to use CBLCNVRT , i will try them out and let you know if i get stuck anywhere . It is a good experience to know a new utility . |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
Quote: |
I was not aware of the utility CBLCNVRT |
Many are not. . . I'm not sure why it is so little known It has been available for years.
Quote: |
But i checked our system and we are using 'CA-EASYTRIEVE PLUS-6.4 0311' so i think this utility will be there also here. |
Yes, it is - you may need an update to the CBLCNVRT macros to handle the newer versions of the compiler as well as incorporate some bug fixes.
Good luck |
|
Back to top |
|
|
Debabrata Pruseth
New User
Joined: 11 Dec 2008 Posts: 59 Location: Pune , India
|
|
|
|
Hi Douglas
Need some help. I referred your earlier post in the following link ---> ibmmainframes.com/viewtopic.php?t=24280&highlight=cblcnvrt
The first STEP i was able to execute successfully and create the GLOSSARY table containing the loadmodule . I am facing issues while running the CBLCNVRT step.
Code: |
000008 //STEP02 EXEC PGM=EZTPA00
000009 //*TEPLIB DD DSN=IDC.EASYPLUS,DISP=SHR
000010 //EZTVFM DD UNIT=SYSDA,SPACE=(CYL,(5,5))
000011 //SYSPRINT DD SYSOUT=*
000012 //GLOSTAB DD DSN=&SYSUID..GLOSSARY.TABLE,DISP=SHR
000013 //*ANDD1 DD DSN=IDC.PANAUDIT.PLUS30C.PANLIB,DISP=SHR
000014 //EASYPGM DD DSN=&SYSUID..CBLCNVRT.OUTPUT,DISP=(NEW,CATLG),
000015 // DCB=(LRECL=80,RECFM=FB,BLKSIZE=0),
000016 // UNIT=SYSDA,SPACE=(CYL,(30,30),RLSE)
000017 //SYSIN DD *
000018 %CBLCNVRT GLOSTAB
000019 /* |
I removed STEPLIB and PANDD1 DD as the one mentioned by you are not in our system and i don't think it's required. The macro CBLCNVRT is there in our system library SYS4.EZTRIEVE.CAIMAC .
Also i haven't given cobol compiler version option as it takes the default.
But the easytreive is giving the following error
Code: |
*******B006 MACRO SYSTEM - PDS , ERROR IN MACRO FILE
1 %CBLCNVRT GLOSTAB
*******B076 REMAINDER OF STATEMENT IS IGNORED
*******B059 PREMATURE END OF FILE
*******A014 PREMATURE TERMINATION DUE TO PREVIOUS ERROR(S) |
I thought that there might be an error in the SYS4.EZTRIEVE.CAIMAC library while reading , so i gave a AUDMACS library for this in the JCL . This time it ran successfully but the output was empty.
Have you encountered with this type of issue . If yes can you let me know the resolution .
Thanks |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
Quote: |
and i don't think it's required |
Why would you believe this? This is the DD where %CBLCNVRT macros are located. . . The ddname might not be PANDD1. It is locally specified. On one of my systems it is PANDD. . .
Suggest you change this:
to this:
Code: |
%CBLCNVRT GLOSTAB COBOL I341 |
assuming you are using Enterprise cobol 3.4.n. |
|
Back to top |
|
|
Debabrata Pruseth
New User
Joined: 11 Dec 2008 Posts: 59 Location: Pune , India
|
|
|
|
Hi Dick
I have tried the changes suggested by you , it's still giving the same error . I tried with giving PANDD and PANDD1 with SYS4.EZTRIEVE.CAIMAC as it contains the %CBLCNVRT macro. Is there anything i need to do further. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
Is the person who installed Easytrieve still available?
One part of the install is to define the Options Table. One of the parameters of the Options Table is MACDD which specifies the ddname for the macro library to be used. It doesn't much matter what is in the jcl if it is not the name specified. . .
Also, Easytrieve supports multiple ways of storing macros - among them are Panvalet, Librarian, VSAM, and partitioned datasets. Is it possible that your installation uses something other than a pds for the macro library?
Another consideraton is that the CAIMAC lib comes with the install media and might not be where the installer intended for applications to reference. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
A bit more. . .
In the library where EZTPA00 executes from, look for a module named MACADD. In that module look for the literal MACADD. About 20 bytes to the rignt of this literal you may see the ddname you need to use in the cblcnvrt jcl. This won't show correctly if the macro library is a not pds (is something else). Still, might be worth a shot.
d |
|
Back to top |
|
|
Debabrata Pruseth
New User
Joined: 11 Dec 2008 Posts: 59 Location: Pune , India
|
|
|
|
dick scherrer wrote: |
Is the person who installed Easytrieve still available?
|
Is there any way to find out the contact person for the same , i mean can the information retrieved through HELP command ar any section in ISPF menu . For each utility installed in the mainframe there must be a support group or contact person but as our organization does not own the mainframe , i am afraid i don't have any clue to find the right person to talk to. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
Unless the installer specifically put something in the Help pages, there probably is nothing.
Finding "who" in another organization may take some effort. . . I'd find the person responsible for cobol on the system and ask who supports easytrieve. |
|
Back to top |
|
|
Debabrata Pruseth
New User
Joined: 11 Dec 2008 Posts: 59 Location: Pune , India
|
|
|
|
Hi Dick
Thanks a lot for your help . I am finally able to execute the CBLCNVRT macro tool.
Code: |
//STEP02 EXEC PGM=EZTPA00
//EZTVFM DD UNIT=SYSDA,SPACE=(CYL,(5,5))
//SYSPRINT DD SYSOUT=*
//GLOSTAB DD DSN=&SYSUID..GLOSSARY.TABLE,DISP=SHR
//AUDMACS DD DSN=SYS4.EZTRIEVE.CAIMAC,DISP=SHR
//SYSIN DD *
%CBLCNVRT GLOSTAB (NUMDEF 3000) COBOL II12
/*
//EASYPGM DD DSN=&SYSUID..CBLCNVRT.OUTPUT,DISP=(NEW,CATLG),
// DCB=(LRECL=80,RECFM=FB,BLKSIZE=0),
// UNIT=SYSDA,SPACE=(CYL,(30,30),RLSE) |
PANDD step is not necessary as AUDMACS can do the needful in this case. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Quote: |
I am finally able to execute the CBLCNVRT macro tool. |
Good to hear
Quote: |
PANDD step is not necessary as AUDMACS can do the needful in this case. |
Yup, the DD is often not PANDD, but some other MAClib. How did you find AUDMACS?
d |
|
Back to top |
|
|
Debabrata Pruseth
New User
Joined: 11 Dec 2008 Posts: 59 Location: Pune , India
|
|
|
|
Refer the following CA Panaudit forum link.
In the second question , posted in the above link , it's mentioned that for running CBLCNVRT Panaudit is not required . Hence i dropped the idea for doing more analysis on PANDD statements . I thought that as CBLCNVRT is a macro let's include this in the AUDMACS library and see the outcome . You had already mentioned earlier , in one of your posts in this forum, that SYS4.**.CAIMAC system library contains the CBLCNVRT macro . I searched for the same , and as it was here in our mainframe , i just included the same in AUDMACS library . It just clicked |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Thanks for the info - it will probably help someone else later
d |
|
Back to top |
|
|
rammohan paulrajan
New User
Joined: 28 Nov 2007 Posts: 11 Location: chennai
|
|
|
|
Hi,
I tried using this JCL to convert my cobol copy book into eztrieve one. I am getting following error on the CBLCNVRT tool
153 DEPENDING_ON_NAME * 40 A
153 *******B055 INVALID LENGTH, TYPE OR DECIMAL PLACES - 40
Do i need to modify anything in the JCL for this since this variable is present in the CBLCNVRT |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
It may help if you post some more of the Easytrieve layout and the corresponding COBOL code.
There was a time when CBLCNVRT did not do well with occurs depending on. This may still be true. |
|
Back to top |
|
|
|