Is it possible to stop script execution on error in Code Editor or Script Manager ?

Hi,

We are currently in a 30 days trial with Toad for Oracle. One thing we were used to with another tool was to stop script execution on error. Toad continue execution, I tried in Code Editor and also in Script Manager.

Do you know if there is an option I’ve not found in order to get this behavior ?

In our case, we would like that a script execution will stop when it will it an error (for example, syntax error, non existing tablespace on index creation,…) instead of continuing execution until the end of the script.

Thanks,

Michael

You should be presented with an error dialog. If you choose the Ignore actions then script execution continues. If you choose Cancel the execution is cancelled. If you run this script in the Editor using F5 you will be presented with that dialog. Click Ignore and you get a second popup for the other bad SELECT. Select Cancel and execution stops.

select * from dual;

select * from dual;

select * from bogus_table;

select * from dual;

select * from bogus_table;

select * from dual;

Hello Michael,

Thanks for your answer, it works like you said in Editor with F5 for example.

Since we have a lot of scripts to run, we batch them using Script Manager.

Did you try it ? (Utilities / Script Manager).

Toad continues script execution and just told us there was an error.

In fact, it is in this tool that we would like a dialog or an option to stop script execution while an error is raised.

I get :


Connection: USER@DATABASE



Script: C:\test.sql completed. 2 errors.

Completed 1 scripts in one connection

Thanks for your first reply, it is appreciated !

Instead of the script manager, have you taken a look at using the script execute action? This may be more in line with what you’re looking for.

Did you try it ? (Utilities / Script Manager).

No, not there, but I tried in Toad's Editor because you said it also failed in the Code Editor. I see what you mean in the Script Manager. Having it proceed automatically seems like a problem.