I have this JSP file in which i'm updating 3 tables one after another. Now the problem that i'm facing is that if some error occurs while updating the second table, the third table doesn't get updated but the first table has the updated value.
How can i implement such an execute Update in which all 3 tables get updated or none gets updated.
Some non transactional changed tables couldn't be rolled
back Error
If you get the error/warning: Warning: Some non transactional changed tables couldn't
be rolled back when trying to do a ROLLBACK, this means that some of the tables you used
in the transaction didn't support transactions. These non transactional tables will not be
affected by the ROLLBACK statement.
The most typical case when this happens is when you have tried to create a table of a type
that is not supported by your mysqld binary. If mysqld doesn't support a table type (or if
the table type is disabled by a startup option) , it will instead create the table type with
the table type that is most resembles to the one you requested, probably MyISAM.
You can check the table type for a table by doing:
SHOW TABLE STATUS LIKE 'table_name'
You can check the extensions your mysqld binary supports by doing:
show variables like 'have_%'
It gave the following output:
Variable_name Value
have_bdb NO
have_gemini NO
have_innodb NO
have_isam YES
have_raid NO
have_openssl NO
Does it mean that my database doesn't support innodb type tables...
If you decide to work with BDB tables, you can either install a MySQL-Max binary or recompile MySQL from source using the --with-bdb flag. BDB tables are available for most operating systems, including Windows, Linux, and Mac OS X.
And if you don't have Gemini, you can get an installer that includes MySQL, PHP, mod_perl and other goodies from the NuSphere website.
This table type is now included by default in most MySQL installations, so if you get current binary from mysql.com, you'll have InnoDB tables.
A day job? In an office? My worst nightmare! Comfort me tiny ad!
Smokeless wood heat with a rocket mass heater
https://woodheat.net
|