Product Documentation

Database Integrity Utilities

Previous Topic

Next Topic

ctchkbin - Checking for affected tables

Execute the ctchkbin utility to scan an entire server or a single database for tables that may be affected by the binary/varbinary issue. The syntax of ctchkbin is as follows:

Operational Model:

  • Standalone

Usage:

ctchkbin.exe [-f] [-s server] [-u username] [-a password] [-d database]

Where:

  • -f - Output only tables that fail check
  • -d database - Scan database. Default: ctreeSQL
  • -d ALL - Scan all databases in session.
  • -s server name - Default: FAIRCOMS
  • -u user name - Default: ADMIN
  • -a user password - Default: ADMIN

Example

ctchkbin.exe –s FAIRCOMS –u ADMIN –a ADMIN –d ctreeSQL

The ctchkbin utility output to the screen the result of the check scan, printing one table per line, with the following columns:

database table status comments

Where:

  • database - database name
  • table - table name
  • status - status code of the check performed on table (please see code listing in the following section)
  • comments - brief comments if table fail scan

Example output

ctreeSQL admin_tb1 0

ctreeSQL admin_tb11 0

ctreeSQL admin_tb12 0

ctreeSQL admin_tb13 3 User may choose CTDB_BINARY_WITH_LENGTH or CTDB_BINARY_WITHOUT_LENGTH

ctreeSQL admin_tb14 3 User may choose CTDB_BINARY_WITH_LENGTH or CTDB_BINARY_WITHOUT_LENGTH

ctreeSQL admin_tb2 0

ctreeSQL admin_tb3 0

ctreeSQL admin_tb4 0

TOCIndex