often need to be in the database to generate documents, due to the way you prefer the script, so you need to use spool time to format, the following simple collation of the Oracle in the format of some of the things, a total of 18, in fact, the commonly used is just a few, Later, we will attach the script of the simple shell operation that I wrote, hoping to be able to communicate with the same need, as well as your own backup.
The items of the set command and their meanings:
ArraySize The number of rows fetched from the database at one time, by default
autocommit is automatically committed, default is off
colsep The delimiter between the selected columns, the default is a space
Echo When executing a script file with the start command, the echo command is used to control whether the SQL statement being executed in the script file is displayed, which is off by default
Feedback When a query selects at least n rows of records, it displays the number of rows returned in the result set item, which defaults to 6
heading whether to display the column headings for the query results, on by default
headsep Specifies that the punctuation mark behind is used to display page labels or column headings, by default, ' | '
Linesize The number of characters per line, that is, the width, the default is
NewPage The number of blank lines between a delimited page and a page
pagesize The number of rows displayed per page, by default
Pause on output per page, if pause text is set, the text is displayed in the lower-left corner
serveroutput Whether the output of a PL/SQL block or stored procedure is displayed, which allows the function to dbms_output. The output of the Put_Line () is displayed on the screen
sqlprompt sqlplus command prompt, default to "Sql>"
Time whether to display the current times of the system at the Sqlplus command prompt, default to OFF
Timing Whether to display the elapsed time for executing SQL statements, PL + + blocks, default to OFF
Trimspool whether to spool the extra space behind each line in the output, default to OFF
underline The symbol for the underscore character, which defaults to "_"
Verify The alternate variable is whether to list the text content of an SQL statement before and after the value of the replacement variable is obtained, by default, on
Description:
Set the XXX command format to:
Set XXX On/off/value
Example: Set timing on-sets the time it takes to display the execution SQL statement, PL + + blocks
Set pagesize 100--Sets display 100 rows per page
The format for displaying a XXX command is: Show xxx
Example: Show timing--view current timing set to ON/off?
Show PageSize--Displays the number of rows displayed per page for the current setting
Reference Documentation:
<<oracle from getting started to mastering >> Water Conservancy and hydropower publishing house Chan Shen Zhang Suzhi 2009.9 Body 140 page chapters: 5.3.2
Oracle Learning database data is saved as a file