Hi,

If I open an OdbcConnection in asp.net 1.1 and start a transaction using "START TRANSACTION" and then close the connection, does the transaction stay open or is it destroyed?

Will both of these scenarios give the same result, even with multiple users?

Scenario 1 (2 connection instances)
  • Open Connection
  • Start Transaction
  • Close Connection
  • Do Some Stuff
  • Open Connection
  • Perform DML (Insert, Update etc)
  • CommitTransaction
  • Close Connection

Scenario 2 (1 connection instance)
  • Open Connection
  • Start Transaction
  • Do Some Stuff
  • Perform DML (Insert, Update etc)
  • CommitTransaction
  • Close Connection


I know Scenario 1 looks weird but I made it simple to illustrate my question. I just need to know if I need to keep the same instance of the connection active during a transaction.

PS Will "SELECT LAST_INSERT_ID()" require the same connection instance as well?

Thanks