I wrote a perl script that connects to a db2 database and does some
select statements then disconnects...in essence it does something like
this:
$db2Out = `db2 connect to sample`;
$db2Out = `db2 select tabschema, tabname from syscat.tables`;
$db2Out = `db2 connect reset`;
This script runs fine on Windows, and AIX, but when I try to
run it on Sun, it does not maintain the session information
between calls - so the first statement establishes a connection,
and it is immediately lost when the call returns, so that
when I do the second call "select", I get an error message
saying that there is no database connection.
Is there a trick to getting this to work on Sun? I have
wrestled with this same problem two or three years ago and
could never figure out how to get the program to run on Sun...
Please tell me if you have any suggestions....
Thanks
Jim