Scripting Issues with iSQL*Plus

Using iSQL*Plus, you can execute your scripts via its browser interface. However, there are differences between command-line SQL*Plus and browser-based SQL*Plus, and not all scripts can be made to execute in both environments.

One issue that you encounter is spool files. Browser-based SQL*Plus runs on an application server. For reasons of security, iSQL*Plus doesn't allow you to write files to that server. Thus, you cannot spool output. After all, iSQL*Plus can hardly spool output through your browser to a file on your PC. The only way to capture output is to copy and paste it from your browser window to a file, and that's only feasible for small amounts of data.

Tip

Copying iSQL*Plus output from a browser window and pasting it into another application works best after you issue SET MARKUP HTML ON PREFORMAT ON. Otherwise, you'll be trying to copy an HTML table rather than the output that you desire.

Another problem you'll encounter when executing scripts from iSQL*Plus is that many SQL*Plus commands are not supported by iSQL*Plus. These include commands such as HOST that would present a security risk by letting you access the application server at the operating system level, and commands such as EDIT that don't apply in a browser-based environment.

Tip

The EDIT command isn't implemented in iSQL*Plus because your script is sitting in an easily edited text box on your browser page.

Figure 8-4 shows the prompt that you'll receive when you execute ex8-4b.sql ...

Get Oracle SQL*Plus: The Definitive Guide, 2nd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.