Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SQL Anywhere 10.0.1 » SQL Anywhere Server - Programming » Database Tools Interface » DBTools structures

a_table_info structure Next Page

a_translate_log structure

Holds information needed for transaction log translation using the DBTools library.

typedef struct a_translate_log {
    unsigned short      version;
    const char *        logname;
    const char *        sqlname;
    p_name              userlist;
    MSG_CALLBACK        confirmrtn;
    MSG_CALLBACK        errorrtn;
    MSG_CALLBACK        msgrtn;
    char                userlisttype;

    a_bit_field         remove_rollback : 1;
    a_bit_field         ansi_sql        : 1;
    a_bit_field         since_checkpoint: 1;
    a_bit_field         omit_comments   : 1;
    a_bit_field         replace         : 1;
    a_bit_field         debug           : 1;
    a_bit_field         include_trigger_trans : 1;
    a_bit_field         comment_trigger_trans : 1;
    a_sql_uint32        since_time;
    const char *        connectparms;
    MSG_CALLBACK        logrtn;

    const char *        _unused1;
    const char *        _unused2;
    a_sql_uint32        debug_dump_size;
    a_bit_field         debug_sql_remote        : 1;
    a_bit_field         debug_dump_hex          : 1;
    a_bit_field         debug_dump_char         : 1;
    a_bit_field         debug_page_offsets      : 1;
    a_bit_field         _unused3                : 1;
    a_bit_field         use_hex_offsets         : 1;
    a_bit_field         use_relative_offsets    : 1;
    a_bit_field         include_audit           : 1;
    a_bit_field         chronological_order     : 1;
    a_bit_field         force_recovery          : 1;
    a_bit_field         include_subsets         : 1;
    a_bit_field         force_chaining          : 1;
    a_sql_uint32        recovery_ops;
    a_sql_uint32        recovery_bytes;

    const char *        include_source_sets;
    const char *        include_destination_sets;
    const char *        include_scan_range;
    const char *        repserver_users;
    const char *        include_tables;
    const char *        include_publications;
    const char *        queueparms;
    a_bit_field         generate_reciprocals    :1;
    a_bit_field         match_mode              :1;
    const char *        match_pos;
    MSG_CALLBACK        statusrtn;
    const char *        encryption_key;
    a_bit_field         show_undo               :1;
    a_bit_field         quiet                   :1;
    const char *        logs_dir;
} a_translate_log;
versionDBTools version number.
lognameName of the transaction log file. If NULL, there is no log.
sqlnameName of the SQL output file. If NULL, then name is based on transaction log file name (-n sets this string).
userlist A linked list of user names. Equivalent to -u user1,... or -x user1,... Select or omit transactions for listed users.
confirmrtnCallback routine for confirming an action.
errorrtnCallback routine for handling an error message.
msgrtnCallback routine for handling an information message.
userlisttypeSet to DBTRAN_INCLUDE_ALL unless you want to include or exclude a list of users. DBTRAN_INCLUDE_SOME for -u, or DBTRAN_EXCLUDE_SOME for -x.
remove_rollbackNormally set to TRUE; Set to FALSE if you want to include rollback transactions in output (equivalent to -a).
ansi_sqlSet to TRUE if you want to produce ANSI standard SQL transactions (equivalent to -s).
since_checkpointSet to TRUE if you want output from most recent checkpoint (equivalent to -f).
omit_commentsReserved; set to FALSE.
replaceReplace existing SQL file without confirmation (equivalent to -y).
debugReserved; set to FALSE.
include_trigger_transSet TRUE to include trigger-generated transactions (equivalent to -g, -sr or -t).
comment_trigger_transSet TRUE to include trigger-generated transactions as comments (equivalent to -z).
since_timeOutput from most recent checkpoint prior to time (-j <time> sets this). The number of minutes since January 1, 0001.

Parameters needed to connect to the database. They take the form of connection strings, such as the following:


The database server would be started by the connection string START parameter. For example:


A full example connection string including the START parameter:


For a list of connection parameters, see Connection parameters.

logrtnCallback routine to write messages only to the log file.
debug_dump_sizeReserved, use 0.
debug_sql_remoteReserved, use FALSE.
debug_dump_hexReserved, use FALSE.
debug_dump_charReserved, use FALSE.
debug_page_offsetsReserved, use FALSE.
use_hex_offsetsReserved, use FALSE.
use_relative_offsetsReserved, use FALSE.
include_auditReserved, use FALSE.
chronological_orderReserved, use FALSE.
force_recoveryReserved, use FALSE.
include_subsetsReserved, use FALSE.
force_chainingReserved, use FALSE.
recovery_opsReserved, use 0.
recovery_bytesReserved, use 0.
include_source_setsReserved, use NULL.
include_destination_setsReserved, use NULL.
include_scan_rangeReserved, use NULL.
repserver_usersReserved, use NULL.
include_tablesReserved, use NULL.
include_publicationsReserved, use NULL.
queueparmsReserved, use NULL.
generate_reciprocalsReserved, use FALSE.
match_modeReserved, use FALSE.
match_posReserved, use NULL.
statusrtnCallback routine for handling a status message.
encryption_keySpecify database encryption key (-ek sets string).
show_undoReserved, use FALSE.
quietSet to TRUE to operate without printing messages (-y).
logs_dirTransaction logs directory (-m dir sets string); sqlname must be set and connect_parms must be NULL.

The members correspond to features accessible from the dbtran utility.

See the dbtools.h header file for additional comments.

See also