string db2ConnectionString = ""; string insertQuery = ""; // INSERT QUERY using (TransactionScope scope = new TransactionScope()) { try { using (DB2Connection myCon = new DB2Connection(db2ConnectionString)) { myCon.Open(); DB2Command cmd = new DB2Command() { CommandType = CommandType.Text, CommandText = insertQuery, // INSERT QUERY Connection = myCon }; _ = cmd.ExecuteNonQuery(); } } catch (Exception ex) { throw; } } **Reproduction Steps:-** 1. Run the C# code with the DB2 Connection String. 2. **Before Calling scope.complete() method, the inserted value is committed in DB2 and able to be seen by querying in the DB2 table.**
string db2ConnectionString = "";
string insertQuery = ""; // INSERT QUERY
using (TransactionScope scope = new TransactionScope())
{
try
{
}
Reproduction Steps:-