RFC_HANDLE SAP_API RfcConnect(char * system_name,
char * ms_hostname,
char * group_name,
char * client,
char * user,
char * password,
char * language,
int * sysnr);
opens an RFC connection via LOAD BALANCING.
With this function the RFC library will try to connect to an application server with the least load (LOAD BALANCING principle) within a group of predefined application servers.
This function is only available for Release 3.0 onwards.
Better use the call RfcOpenEx.
This function has the following advantages:
· The load in the SAP system is distributed to different application servers.
· Only the host name of the message server and its port number of the according SAP system are required in the host file and the services file.
Information about the SAP gateway, application server, system number, etc. as parameters for RfcOpen or RfcOpenExt or as parameters in sideinfo are no longer necessary. Even the sideinfo is no longer required.
This function is defined in SAPRFC.H.
· returns a handle to the RFC connection (RFC_HANDLE) or RFC_HANDLE_NULL if the connection cannot be opened.
name of the SAP system
host name of the message server
name of a specific group of application servers
signon data: client
signon data: user-ID
signon data: password
signon data: language
name of the connected application server (output parameter)
system number of the connected SAP system (output parameter)