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;
Member | Description |
---|---|
version | DBTools version number. |
logname | Name of the transaction log file. If NULL, there is no log. |
sqlname | Name 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. |
confirmrtn | Callback routine for confirming an action. |
errorrtn | Callback routine for handling an error message. |
msgrtn | Callback routine for handling an information message. |
userlisttype | Set 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_rollback | Normally set to TRUE; Set to FALSE if you want to include rollback transactions in output (equivalent to -a). |
ansi_sql | Set to TRUE if you want to produce ANSI standard SQL transactions (equivalent to -s). |
since_checkpoint | Set to TRUE if you want output from most recent checkpoint (equivalent to -f). |
omit_comments | Reserved; set to FALSE. |
replace | Replace existing SQL file without confirmation (equivalent to -y). |
debug | Reserved; set to FALSE. |
include_trigger_trans | Set TRUE to include trigger-generated transactions (equivalent to -g, -sr or -t). |
comment_trigger_trans | Set TRUE to include trigger-generated transactions as comments (equivalent to -z). |
since_time | Output from most recent checkpoint prior to time (-j <time> sets this). The number of minutes since January 1, 0001. |
connectparms |
Parameters needed to connect to the database. They take the form of connection strings, such as the following: "UID=DBA;PWD=sql;DBF=samples-dir\demo.db" The database server would be started by the connection string START parameter. For example: "START=d:\sqlany10\win32\dbeng10.exe" A full example connection string including the START parameter: "UID=DBA;PWD=sql;DBF=samples-dir\demo.db;START=d:\sqlany10\win32\dbeng10.exe" For a list of connection parameters, see Connection parameters. |
logrtn | Callback routine to write messages only to the log file. |
debug_dump_size | Reserved, use 0. |
debug_sql_remote | Reserved, use FALSE. |
debug_dump_hex | Reserved, use FALSE. |
debug_dump_char | Reserved, use FALSE. |
debug_page_offsets | Reserved, use FALSE. |
use_hex_offsets | Reserved, use FALSE. |
use_relative_offsets | Reserved, use FALSE. |
include_audit | Reserved, use FALSE. |
chronological_order | Reserved, use FALSE. |
force_recovery | Reserved, use FALSE. |
include_subsets | Reserved, use FALSE. |
force_chaining | Reserved, use FALSE. |
recovery_ops | Reserved, use 0. |
recovery_bytes | Reserved, use 0. |
include_source_sets | Reserved, use NULL. |
include_destination_sets | Reserved, use NULL. |
include_scan_range | Reserved, use NULL. |
repserver_users | Reserved, use NULL. |
include_tables | Reserved, use NULL. |
include_publications | Reserved, use NULL. |
queueparms | Reserved, use NULL. |
generate_reciprocals | Reserved, use FALSE. |
match_mode | Reserved, use FALSE. |
match_pos | Reserved, use NULL. |
statusrtn | Callback routine for handling a status message. |
encryption_key | Specify database encryption key (-ek sets string). |
show_undo | Reserved, use FALSE. |
quiet | Set to TRUE to operate without printing messages (-y). |
logs_dir | Transaction 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.