Note: that's just something to try -- I don't have a clue whether it will work.... print SQLP "\@$script_name; \n" or die "cannot write in doScript"; # add: print SQLP "exit\n" or die "cannot write exit to sqlplus in doScript"; close SQLP or die "cannot close in doScript"; ... ****** Start t.sql select sysdate from dual / ****** end t.sql ...
Is it the case that you have no hope of installing DBI and DBD::Oracle on the platforms involved? This would make it a lot easier to communicate with oracle through perl, without exposing account names/passwords.
One other point: are you sure you want to redirect sqlplus output to $output_file_name via the ">>" (append) operator? Do you intend to read that file back after a sequence of queries has been completed, or is it being read back after each query?
In reply to Re: read return value from a sql script using piped open
by graff
in thread read return value from a sql script using piped open
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |