This function is to be installed by RfcInstallTransactionControl. The syntax is:
int RFC_ON_CHECK_TID(RFC_TID transactionId)
The function is called when a local transaction is starting. Since a transactional RFC call can be issued many times by the client system, the function is responsible for storing the transaction-ID in permanent storage. If the client system tries starting the same transaction a second time, the function has to return 1.
If this functions has access to a SQL database, it should
perform an operation like
Insert Into SomeTable values ( :transactionId);
where the table 'SomeTable' must have a unique index over the transaction-ID. If another process has also inserted the same transaction-ID, the second process has to wait until the transaction is completed by the first process. If the transaction is completed by another process (the Insert command returns with some 'Duplicate Record' error code), the function must return 1 to indicate to skip the transaction.