Skip to Main Content

Breadcrumb

Question and Answer

Connor McDonald

Thanks for the question, Elango.

Asked: June 13, 2019 - 7:09 am UTC

Last updated: October 30, 2023 - 5:39 am UTC

Version: 11.2.0.4

Viewed 10K+ times! This question is

You Asked

i have been encountering an error while executing a sql file.

The sql file contains only one insert statement and inserts huge LOB into a table which spans around 400 pages if pasted in word.

I encounter Error 45 as soon as i execute but the same executes fine in sql developer. Kindly suggest.

and Connor said...

A couple of potential reasons

1) You're using a non-local file system that is incompatible with SQL Plus. See MOS Note 281450.1. Try copying the script to a local file system to see if that helps.

2) You're environment is not set correctly (although that normally gives a different error, eg)

[oracle@db192 ~]$ sqlplus qwe/qwe
Error 6 initializing SQL*Plus
SP2-0667: Message file sp1<lang>.msb not found


if my oracle home is not correctly.

Rating

  (1 rating)

Is this answer out of date? If it is, please let us know via a Comment

Comments

And on the local filesystem?

Alesinskyy, October 23, 2023 - 3:43 pm UTC

Today I encountered this error on the local filesystem at the very end of the script execution:
14557  EXECUTE DBMS_OUTPUT.PUT_LINE('Total Time Elapsed for Europe Merge Operation: '||:n||' Minutes');
14558  spool off
14559  Error 45 initializing SQL*Plus
Internal error



Connor McDonald
October 30, 2023 - 5:39 am UTC

A common cause of that is "garbage" at the end of your script, and by "garbage" I mean some characters that might have been created/inserted by the tool that last edited the script etc.

Things like page break characters, smart quotes etc.

If you have access to "od", perhaps try an "od" on the file to see what characters come after your "spool" command