Oracle® OLAP DML Reference 11g Release 1 (11.1) Part Number B28126-01 |
|
|
View PDF |
The RECAP command sends statements that were previously entered during the current session to the current outfile or to a file that you specify. The statements are copied from the command log, which is a list of up to 256 statements that you have entered most recently during the current session.
Note:
RECAP statements are not included in the command log.Syntax
RECAP [number|ALL] [ 'search-text' ] [ FILE file-name ]
Arguments
A positive INTEGER
that indicates the number of statements to be provided. When you specify search-text, RECAP provides this number of statements from the subset that contains the search-text string. When you do not specify search-text, RECAP provides this number of statements from the most recently executed portion of the command log. The default number is 10.
When you specify search-text, ALL requests every statement that meets the search requirements. When you do not specify search-text, ALL requests every statement in the command log.
A quoted text literal. When you specify this argument, RECAP searches the statements in the command log for the ones that contain search-text. The search is not case-sensitive. These statements will then compose the subset from which RECAP provides number or ALL statements.
Writes the output of a RECAP statement to the specified file For file-name specify a text expression that is the name of the file to which output should be written. Unless the file is in the current directory, you must include the name of the directory object in the name of the file.
Note:
Directory objects are defined in the database, and they control access to directories and file in those directories. You can use a CDA statement to identify and specify a current directory object. Contact your Oracle DBA for access rights to a directory object where your database user name can read and write files.Notes
Order of search-text Argument
When you use both the search-text and the ALL or number arguments, you must specify search-text second.
RECAP with No Argument
When you specify RECAP without an argument, the ten most recent statements are provided.
Re-Executing Statements
You can use the output of RECAP to edit a previously executed statement with REEDIT, or reexecute a previously executed statement with REDO.
Identifying Files and Directories
When specifying files and directories in OLAP DML statements, it is good practice to always enclose them in single quotes.
Examples
Example 10-89 Obtaining the Last Three Statements Containing "actual"
The following RECAP statement requests the three most recent statements that included the text literal "actual."
RECAP 3 'actual'
This statement could produce the following output.
COMMAND LOG
3: dsc actual
5: report total(actual)
8: report average(actual)