Skip to Main Content

Oracle Database Discussions

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Error 45 initializing SQL*Plus Internal Error while running an SQL using SQLPlus

3633557Oct 5 2023 — edited Oct 11 2023

I am trying to execute a shell script that has below code, on Linux server with Oracle 19c installed. I am getting error “Error 45 initializing SQL*Plus Internal Error”.

____________________________________________________________________________

sqlplus uname/'<password>'@DB <<EOF

SELECT 'Refreshed successfully' STATUS FROM DUAL;

exit

EOF

exit 0

____________________________________________________________________________

It establishes the connection and connects to oracle database with credentials, but the next SELECT statement is throwing the error. The error screenshot is as follows:

But, When I try to execute in command line the sqlplus statemnt to connect to the database and run the same SELECT statement manually (Not via Shell Script), It runs without any issues.

Please suggest what has to be checked/modified to resolve this issue.

Need this issue fixed as soon as possible. Any suggestions are welcome.

Comments
Post Details
Added on Oct 5 2023
1 comment
3,261 views