MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

call cobol program from a PL/1

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Application Programming
View previous topic :: View next topic  
Author Message
harikiran2001
Beginner


Joined: 02 Jan 2008
Posts: 10
Topics: 4

PostPosted: Fri Jan 07, 2011 2:48 pm    Post subject: call cobol program from a PL/1 Reply with quote

HI I am new to PLi programming.
I am calling a cobol program from a PL/1 program.

PL/1 program:
Code:

MYPRG:PROCEDURE OPTIONS(MAIN);             
DCL SAMPLE EXTERNAL ENTRY( ) OPTIONS(COBOL);
PUT SKIP LIST(0);                           
PUT PAGE LIST((70)'*');                     
PUT PAGE LINE(2) LIST('MCMILLAN');         
  CALL SAMPLE( );                           
END;                       

here sample is a coobl program.
The following the job used for compiling/linking/running.
Code:

// JCLLIB ORDER=(SYS1.PLI.PROCLIB)
//PLIO   EXEC  PLIXCL,PARM.PLI='LIST,MAP,FLOW,GOSTMT'   
//STEPLIB  DD DSN=SYS1.PLI.PLICOMP,DISP=SHR             
//SYSPRINT DD  SYSOUT=*                                 
//SYSIN    DD  DSN=PBCL.SAM.SOURCE(VISHNPL3),         
//   DISP=SHR                                           
//SYSUT1   DD  UNIT=SYSDA,SPACE=(CYL,(2,2))             
//LKED.SYSLMOD DD  DSN=PBCL.SAM.LOAD(VISHNPL3),       
//   DISP=OLD                                           
//STEP1  EXEC  PGM=VISHNPL3                             
//STEPLIB  DD DSN=PBCL.SAM.LOAD,DISP=SHR             
//SYSPRINT DD  SYSOUT=*                                 
//SYSOUT   DD  SYSOUT=*                                                 

I am getting the following error.
Code:

EW2456E 9207 SYMBOL SAMPLE UNRESOLVED.  MEMBER COULD NOT BE INCLUDED FROM THE DEDESIGNATED CALL LIBRARY.

PLease help..
Back to top
View user's profile Send private message
papadi
Supermod


Joined: 20 Oct 2009
Posts: 594
Topics: 1

PostPosted: Fri Jan 07, 2011 3:06 pm    Post subject: Reply with quote

Suggest you talk with whoever supports compiling processes on your system and make sure you have all of the needed libraries in the compile process. . .
_________________
All the best,

di
Back to top
View user's profile Send private message
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12380
Topics: 75
Location: San Jose

PostPosted: Fri Jan 07, 2011 3:15 pm    Post subject: Reply with quote

harikiran2001,

Your LINK EDIT step should have SYSLIB pointing to the dataset that contains the COBOL load module SAMPE.

Code:

//LKED.SYSLIB DD  DSN=Your cobol pgm load library,       
//   DISP=OLD                                           


and your Link Edit sysin should have an INCLUDE for SAMPLE
Code:

//LKED.SYSIN    DD *       
 INCLUDE SYSLIB(SAMPLE)
 NAME VISHNPL3(R)           
 INCLUDE OBJ(VISHNPL3)   
//*


Kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
harikiran2001
Beginner


Joined: 02 Jan 2008
Posts: 10
Topics: 4

PostPosted: Fri Jan 07, 2011 4:16 pm    Post subject: Reply with quote

Thanks a lot Kolusu..It worked...thanks...
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Application Programming All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group