Problem running oracle script from command line using sqlplus

前端 未结 6 605
暖寄归人
暖寄归人 2021-01-11 20:14

I\'m having a problem trying to run my sql script into oracle using sqlplus. The script just populates some dummy data:

DECLARE 
  role1Id NUMBER;
  user1Id          


        
6条回答
  •  甜味超标
    2021-01-11 21:06

    I was seeing this problem as well with certain scripts that would execute fine in a client like TOAD, but when being executed via SQLPlus with the @script directive instead of hanging, the SQLPlus client would return a prompt with a number on it which corresponded to the number of lines in the script being executed (+1).

    For example, if we executed a script named 'doit.sql' that had 70 lines we would start SQLPlus with the appropriate command and enter:

    > @doit.sql

    Then we would see:

    71:

    Pressing enter at this point would return

    72:

    We were able to get these scripts executed by entering / at the prompt and pressing enter.

提交回复
热议问题