6.142 SHOWSYNTAX

Valid For

Replicat

Description

Use the SHOWSYNTAX parameter to start an interactive session where you can view each Replicat SQL statement before it is applied. Viewing SQL statements that failed may help you diagnose the cause of the problem. For example, you could find out that the WHERE clause is using a non-indexed column.

As long as a data type can be applied with dynamic SQL and the column data is bound with a SQL statement, Replicat shows some or all of the data in string form, hexadecimal form, or as a data identifier, depending on the data type. By default, Replicat does not show LOB data or other data types that are treated as a LOB by the database or by Oracle GoldenGate, whether or not the data is bound in SQL. Examples are LOB, XML, and UDT data types. Instead, Replicat shows a data identifier, for example "<LOB data>." To display this type of data, specify the INCLUDELOB option of SHOWSYNTAX. If the column data is not bound in a SQL statement, Replicat does not show the data even when INCLUDELOB is used.

If CHAR/VARCHAR/CLOB or NCHAR/NVARCHAR/NCLOB character data has an unprintable character (U+0000 to U+001F), the character is escaped and displayed in \xx form, where xx is a decimal value that ranges from 00 to 31.

The first time that you use SHOWSYNTAX, request guidance from Oracle Support. It is a debugging parameter and can cause unwanted results if used improperly. It requires manual intervention, which suspends automated processing and can cause backlogs and latency. Use SHOWSYNTAX in a test environment. Create duplicates of your Replicat groups and target tables so that the production environment is not affected.

SHOWSYNTAX is not supported for a coordinated Replicat group.

If used for an integrated Replicat group, sqltrace is enabled for the associated database apply process.

If you capture XML column data using Integrated Extract, the column is captured as updated column even if you do not update the column. As a result of this behavior, SHOWSYNTAX shows the XML column as updated column. However, if you capture the table using Classic Extract, the XML column does not appear in the SHOWSYNTAX SQL statement if the column is not part of the update.

To use SHOWSYNTAX, Replicat must be started from the command shell of the operating system. Do not use SHOWSYNTAX if Replicat is started through GGSCI.

BATCHSQL processing is suspended when SHOWSYNTAX is running. BATCHSQL mode is resumed when Replicat is re-started without SHOWSYNTAX.

To use SHOWSYNTAX, do the following:

  1. From the Oracle GoldenGate home directory, start Replicat from the command shell of the operating system using the following syntax. This syntax eliminates the reportfile option and directs the output to the screen.

    replicat paramfile dirprm/Replicat_name.prm
    
  2. The first SQL statement is displayed with some prompts.

    • Choose Keep Displaying (the default) to execute the current statement and display the next one.

    • Choose Stop Display to resume normal processing and stop printing SQL statements to screen.

  3. When finished viewing syntax, remove SHOWSYNTAX from the parameter file.

Default

None

Syntax

SHOWSYNTAX [APPLY | NOAPPLY] [INCLUDELOB [max_bytes | ALL]]
APPLY | NOAPPLY

Controls whether or not Replicat applies the data that is displayed with SHOWSYNTAX to the target database. The default is APPLY (apply the data to the target database). NOAPPLY prevents the application of the data to the target and does not write the records to the discard file.

INCLUDELOB [max_bytes] | ALL

Includes LOB, XML, and UDT data in the SHOWSYNTAX output. Without this option, only a data identifier is displayed, such as "<LOB data>." The default is 2.

max_bytes

Specifies the maximum length of LOB, XML, or UDT data that is displayed. Valid units are K, M, or G. The default is to display the first 2K bytes.

ALL

Displays LOB data in its entirety.

Example

SHOWSYNTAX INCLUDELOB 1M