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

Dynamic file allocation


IBM Mainframe Forums -> COBOL Programming
Post new topic   This topic is locked: you cannot edit posts or make replies.
View previous topic :: View next topic  
Author Message
rashmi123

New User


Joined: 04 Jun 2007
Posts: 25
Location: Pune

PostPosted: Tue Feb 24, 2009 2:48 am
Reply with quote

Hi all,

I am using the "setenv" function in my cobol program to dynamically allocate files.
I read on one of the sites that to use setenv() we need to compile the program using option PGMNAME(LONGMIXED).

I did so, but I am getting the following error:

IGYDS1046-E A user-defined word was found as a "PROGRAM-ID" name under the "PGMNAME(LONGMIXED)" compiler option. When "PGMNAME(LONGMIXED)" is in effect, a literal is expected for the "PROGRAM-ID" name. The name was accepted in its uppercased format.


Please advise.

Thanks
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 Feb 24, 2009 3:39 am
Reply with quote

Hello,

Please post the first part of your program - from the beginning to the just before the ENVIRONMENT DIVISION.
Back to top
View user's profile Send private message
rashmi123

New User


Joined: 04 Jun 2007
Posts: 25
Location: Pune

PostPosted: Tue Feb 24, 2009 3:43 am
Reply with quote

Here u go:

IDENTIFICATION DIVISION.
PROGRAM-ID. DW3FMTPG.
DATE-WRITTEN. NOVEMBER 2005.
DATE-COMPILED. NOVEMBER 2005.
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 Feb 24, 2009 4:11 am
Reply with quote

Hello,

You might try:
Code:
PROGRAM-ID. 'DW3FMTPG'.
Which compiler are you using?
Back to top
View user's profile Send private message
rashmi123

New User


Joined: 04 Jun 2007
Posts: 25
Location: Pune

PostPosted: Tue Feb 24, 2009 9:32 am
Reply with quote

I put the program name in quotes as suggested. It is still not compiling but the error went away. There now seems to be some problem during linking.

My COBOL is IBM Enterprise COBOL for z/OS 4.1.0.

The error message is:

z/OS V1 R9 BINDER 21:45:11 MONDAY FEBRUARY 23, 2009
BATCH EMULATOR JOB(NBK6BIWC) STEP(LINKLOD ) PGM= IEWL
IEW2278I B352 INVOCATION PARAMETERS - LIST,XREF,MAP,

IEW2322I 1220 1 SETSSI 5C731059
IEW2322I 1220 2 IDENTIFY DW3FMTPG('DW3FMTPG/5C731059/DW30000959')
IEW2322I 1220 3 NAME DW3FMTPG(R)
IEW2606S 4B39 MODULE INCORPORATES VERSION 3 PROGRAM OBJECT FEATURES AND CANNOT BE SAVED IN LOAD MODULE FORMAT.

Any clue??
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 Feb 24, 2009 9:56 am
Reply with quote

Hello,

Backing up a bit. . .
Quote:
I read on one of the sites that to use setenv() we need to compile the program using option PGMNAME(LONGMIXED).
Are you certain this is true? Have you tried without this?

This was the solution to the IEW2606S 4B39
Quote:
SOLUTION:
The program object has been compiled with the NOLONGNAME
option.


It may be worth a try - "MODULE INCORPORATES VERSION 3 PROGRAM OBJECT FEATURES AND CANNOT BE SAVED IN LOAD MODULE FORMAT." looks kind of final. . .
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   This topic is locked: you cannot edit posts or make replies. View Bookmarks
All times are GMT + 6 Hours
Forum Index -> COBOL Programming

 


Similar Topics
Topic Forum Replies
No new posts How to split large record length file... DFSORT/ICETOOL 10
No new posts Extracting Variable decimal numbers f... DFSORT/ICETOOL 17
No new posts SFTP Issue - destination file record ... All Other Mainframe Topics 2
No new posts Access to non cataloged VSAM file JCL & VSAM 18
No new posts Need help for File Aid JCL to extract... Compuware & Other Tools 23
Search our Forums:

Back to Top