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

how do you know the version of COBOL just by viewing code


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

New User


Joined: 22 Jan 2008
Posts: 2
Location: hyderabad

PostPosted: Tue Jan 22, 2008 3:58 pm
Reply with quote

Hi all

Is there a way by which i can know which version of COBOL it is just looking at the COBOL code.If not, then is there a standard practice/procedure to know the COBOL version normally in the industry.
Back to top
View user's profile Send private message
murmohk1

Senior Member


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

PostPosted: Tue Jan 22, 2008 4:20 pm
Reply with quote

Manasa,

Quote:
Is there a way by which i can know which version of COBOL it is just looking at the COBOL code

No, unless you are a COBOL expert across versions & flavours.

Quote:
If not, then is there a standard practice/procedure to know the COBOL version normally in the industry.

Check your compiler messages.
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 22, 2008 9:47 pm
Reply with quote

Hello,

Most COBOL code will work properly on multiple versions of COBOL.

When you compile a program, the compiler generates the information you want. The first printed line of a compile should look like:
Quote:
PP 5655-G53 IBM ENTERPRISE COBOL FOR Z/OS 3.4.1
depending on which compiler you are using.
Back to top
View user's profile Send private message
anv2005

New User


Joined: 14 Jul 2005
Posts: 44
Location: US

PostPosted: Tue Jan 22, 2008 9:55 pm
Reply with quote

Browse your load module and look for COBOL compiler's product ID number, e.g. 5655G53.

The following IBM page relates the COBOL compiler product ID and product name:

www-03.ibm.com/servers/eserver/zseries/zos/le/history/cobmvs.html

Beware, that the target load module may consists of many separately compiled COBOL programs. These programs could have been compiled using different COBOL compilers.

I hope this helps.
Back to top
View user's profile Send private message
anv2005

New User


Joined: 14 Jul 2005
Posts: 44
Location: US

PostPosted: Tue Jan 22, 2008 9:58 pm
Reply with quote

FYI: There is a way to ascertain for sure what COBOL, PLI or IBM LE compiler was used to prepare your program at run-time or during debugging. You have to traverse the IBM LE control blocks and program headers. Our software package does just that.
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 Replace each space in cobol string wi... COBOL Programming 3
No new posts COBOL -Linkage Section-Case Sensitive COBOL Programming 1
No new posts isfline didnt work in rexx at z/OS ve... CLIST & REXX 7
No new posts run rexx code with jcl CLIST & REXX 15
No new posts COBOL ZOS Web Enablement Toolkit HTTP... COBOL Programming 0
Search our Forums:

Back to Top