CurrentTransaction with the RuntimePublic_api.SetActiveConnectionString

CurrentTransaction with the RuntimePublic_api.SetActiveConnectionString

  
Hi,

Question regarding the SetActiveConnectionString and the code
(OracleTransaction)DatabaseAccess.ForRunningApplication().GetRequestTransaction().GetDriverTransaction();
Will this be the same connection for the session and action?

 
Hi,

By SetActiveConnectionString you mean the "SetConnectionStringForSession" method right?
That method takes a connectioName as parameter, so it only affects external databases, not the Platform database.

So to get a transaction from that connection it would be using the the ForExternalDatabase(...) method instead of the ForRunningApplication().

(OracleTransaction)DatabaseAccess.ForExternalDatabase(connectionName).GetRequestTransaction().GetDriverTransaction();


Regards,
João Rosado