PC SOFT

ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Home | Sign in | English EN
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Others
Stored procedures
Changes the DNS name of the replication server if it has a new name.
Caution: This operation must be done if only the server name has been changed (other aspects of the server are left unchanged: configuration, database architecture and system files must be the same). In particular, the replication configuration in the HFConf.ini file must not have been changed. Example:
[REPLICATION]
PRIORITY=2
PASSWORD=XXXXX
PORT=9792
ROLE=3
SERVER_ID=2
Example
listRS is array of hRSConfig
 
// List of replications
listRS = HRSListConfig(MyConnection1)
FOR EACH ConfigReplication OF listRS
// If the configuration must be changed
ConfigReplication.Server = "MyNewServerName:4997"
IF NOT HRSRenameServer(MyConnection1, ConfigReplication) THEN
Trace(HErrorInfo())
END
END
Syntax
<Result> = HRSRenameServer(<Connection> , <Replication to rename>)
<Result>: Boolean
  • True if the replication was modified,
  • False otherwise. HErrorInfo is used to identify the error.
<Connection>: Character string or Connection variable
Connection to the master HFSQL server on which the replication configuration must be changed. This connection corresponds to:
<Replication to rename>: hRSConfig variable
Name of the hRSConfig variable describing the modified replication to update.
Remarks
  • This operation must be done only if the server is identical, except for its DNS name. The configuration, database architecture and system files must be the same.
  • HRSRenameServer does not allow you to "duplicate" or "move" a replication to another server.
  • In a bidirectional replication, HRSRenameServer must be called on the connection that corresponds to the server whose name has not been changed.
  • In a unidirectional replication, HRSRenameServer must be called on the connection that corresponds to the master server.
  • In a unidirectional replication, if the name of the master server has changed, no additional actions are required. The modification will be automatically applied.
Business / UI classification: Business Logic
Component: wd280hf.dll
Minimum version required
  • Version 27
This page is also available for…
Comments
Click [Add] to post a comment