Use this stored procedure to programmatically decide when a rescan is required.
Name | Value | Description |
---|---|---|
publication_n (in) |
publication |
Deprecated. Use subscription_n instead. The publications being synchronized, where n is an integer. There is one publication_n entry for each publication being synchronized. The numbering of n starts at zero. |
MobiLink user (in) |
MobiLink user name |
The MobiLink user for which you are synchronizing. |
discarded storage (in) |
number |
The number of bytes of discarded memory after the last synchronization. |
rescan (in|out) |
true | false |
If set to True by the hook, dbmlsync performs a complete rescan before the next synchronization. On entry, this value is set to False. |
script version (in) |
script version name |
The MobiLink script version to be used for the synchronization. |
subscription_n (in) | subscription name(s) | The names of subscriptions being synchronized where n is an integer. This is one subscription_n entry for each subscription being synchronized. The numbering of n starts at zero. |
When more than one -n option or -s option is specified in the command line, dbmlsync may experience fragmentation which results in discarded memory. The discarded memory can be recovered by rescanning the database transaction log. This hook allows you to decide if dbmlsync should rescan the database transaction log to recover memory.
When no other condition has been met that would force a rescan, this hook is called immediately after the sp_hook_dbmlsync_process_exit_code hook.
The following example cause a log scan if the discarded storage is greater than 1000 bytes.
CREATE PROCEDURE sp_hook_dbmlsync_log_rescan () BEGIN IF EXISTS(SELECT * FROM #hook_dict WHERE name = 'Discarded storage' AND value>1000) THEN UPDATE #hook_dict SET value ='true' WHERE name='Rescan'; END IF; END; |
Discuss this page in DocCommentXchange.
|
Copyright © 2012, iAnywhere Solutions, Inc. - SQL Anywhere 12.0.1 |