Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Ksh script within cobol

Status
Not open for further replies.

jmanj

Programmer
May 20, 2003
298
US
I'm hoping that somebody might have a similar problem that I'm having with a ksh script. I have a script that is called within a cobol program as the last statement. This program/script runs perfectly well under solaris. However, under AIX the cobol pgm runs okay but not the script. If I ran the script in a command line(AIX) it works perfectly.

Does this looks familiar? Any help would be appreciated..

note: the script is just a simple copy and move statement.

 
What exactly are you trying to copy/move? Perhaps your script does not get the same current directory as it did under Solaris? Try to cd to that dir first in the script.

something like:
Code:
cd /path/to/your/dir
cp file1 file2
mv file3 /path/to/other/dir

Or modify the script so that it uses full pathnames instead of relative path names.

Another problem might be that the cobol runtime userid doesn't have the necessary user credentials to copy/move the files in question...
Do you have a stdout or stderr of the script when it runs?
if so, please post that here.


HTH,

p5wizard
 
Gentlemen, Thanks for your responses. I found the problem is in the cobol statement that precede the call command. Once I remove the statement(which is ligit in solaris), the script ran perfectly well.

Again, thanks for sharing your thoughts.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top