Transactions not working?
Posted by: Stephan Huewe
Date: December 23, 2009 01:28PM

Hello,

is there another way to use transaction without the classes but with old classic sql statements?

Unfortunately my easy sample does not work:

clsMysql.ExecuteSQL("SET autocommit=0;", GetDBName());
clsMysql.ExecuteSQL("START TRANSACTION;", GetDBName());
clsMysql.ExecuteSQL("INSERT INTO mytable (NAME) VALUES ('DEMO');",GetDBName());
clsMysql.ExecuteSQL("COMMIT;",GetDBName());
clsMysql.ExecuteSQL("SET autocommit=1;", GetDBName());

Is there something I have to set in connection string or MySqlConnection / MySqlCommand object?

Thank you in advance.

Options: ReplyQuote


Subject
Written By
Posted
Transactions not working?
December 23, 2009 01:28PM
January 05, 2010 08:24PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.