dmshowbookmark - Display bookmark information

Use this command on your CDC Replication target system to obtain the replication position (bookmark) in the stream of change data for a subscription.

CAUTION:
Improper use of this command in conjunction with the dmsetbookmark command can result in data loss or data duplication. You should only execute the dmsetbookmark command when directed by IBM Technical Support.

After generating the replication position information with this command, you can use the dmsetbookmark command on the source system to set the replication position for a subscription.

Applies To—Target

Syntax

dmshowbookmark [-I <name>] -s <source ID>  
[-f <binary>] [-x <file>] [-v] [-L <locale>]

Parameters

[-I <name>]
The name of the CDC Replication instance. You can set the TSINSTANCE environment variable to the name of your CDC Replication instance. After this is complete, you no longer have to specify the instance when issuing commands.
-s <source ID>
Specifies the source ID of the subscription for which you want to obtain the replication position (bookmark).
Source IDs are automatically generated based on truncating the subscription name to 8 characters during subscription creation. Source IDs must be unique.
[-f <binary>]
Specifies the name of the binary file that will be generated by this command. The generated file contains information about the replication position (bookmark) for the specified subscription.
You can specify an absolute path for the location where you want to create the file. If you do not specify an absolute path, the file is created in the CDC Replication installation directory.
Use the -f parameter in the dmsetbookmark command to read the binary file generated by this parameter.
Note: Use the -x parameter if you are issuing this command from the target of a DB2® for LUW DPF source environment.
[-x <file>]
Specifies the name of the XML file that will be generated by this command. The generated file contains information about the replication position (bookmark) for the specified subscription. Use this parameter if you are replicating from a DB2 for LUW DPF source environment. The XML file contains replication positions (bookmarks) for all partitions.
You can specify an absolute path for the location where you want to create the file. If you do not specify an absolute path, the file is created in the CDC Replication installation directory.
Use the -f parameter in the dmsetbookmark command to read the XML file generated by this parameter.
[-v]
Displays verbose information about the replication position (bookmark), including a hexadecimal-encoded string. The amount of information displayed depends on the type and version of the source engine. The hexadecimal-encoded string is always displayed. This parameter displays a subset of what the dmdecodebookmark command displays. If not specified, only a hexadecimal-encoded string is displayed.
Note: Use the -x parameter if you are issuing this command from the target of a DB2 LUW DPF source environment.
[-L <locale>]
The name of the locale used for the CDC Replication instance. The default is your machine's locale.

Result

This command returns a value of 0 if the command was successful and a non-zero value if the command fails.

Examples

dmshowbookmark -I MYINSTANCE -s MASTER -f bookmark

CDC Replication obtains the replication position (bookmark) information for the specified instance and the MASTER source ID. Replication position (bookmark) information is contained in the bookmark binary file which will be placed in the CDC Replication installation directory since no absolute path has been specified.

dmshowbookmark -I MYINSTANCE -s FINANCE -x mybookmarks

CDC Replication obtains the replication position (bookmark) information for the specified instance and the FINANCE source ID. Replication position (bookmark) information is contained in the mybookmarks XML file which will be placed in the CDC Replication installation directory since no absolute path has been specified.