I have a shell script (bash) that executes a sqlplus command, and it works perfectly when I run it from a terminal (or SSH clients like PuTTY or Xshell), what means I can read its output. Now I created a web interface where the user can start this script, but the execution fails because this same sqlplus seems not to be executed. Have a look at the following simplified examples I created:
Test shell script (test.sh):
echo 1
sqlplus -s SIEBEL/SIEBEL@SBLQA02 @select.sql
echo 2
select.sql:
select 'a' from dual;
exit;
Output generated in a terminal:
1
'
-
a
2
Output generated on a web client (so far I tried to use Ganymed SSH-2 for Java and sshj, producing the same result):
1
2
As you can see, only the simple echo commands have generated output. What happened to the sqlplus output? Am missing anything?
Thanks in advance for any help!