Thank you Heikki! We had a problem where code in one of our program's EJB did not turn the FK CHECK back to 1.
Another program that was started afterwards caused some bad data to be inserted in the database - as though the FK CHECK was = 0. It wasn't until we turned the FK CHECK back to 1 in the first program that the second one started to behave correctly. We use JBoss and MySQL 4.0.21. Any feedback on the nature of JBoss-MySQL transaction management will be most helpful to us. Thank you much in advance - Noga -----Original Message----- From: Heikki Tuuri [mailto:[EMAIL PROTECTED] Sent: Friday, November 18, 2005 2:56 PM To: Noga Woronoff Cc: Heikki Tuuri Subject: Re: Regarding SET FOREIGN_KEY_CHECKS=0; Noga, please forward this communication to mysql@lists.mysql.com > mysql -u root -p -e "SET FOREIGN_KEY_CHECKS=0;" < /tmp/dump.sql FOREIGN_KEY_CHECKS is a per-session variable. When the above shell command returns, the session ends. Thus, no problem for others. Regards, Heikki Oracle/Innobase Noga Woronoff wrote: > Hi Heikki - > > > > I don't know which user group to use and wonder whether you may answer a > question for me? > > > > When you perform: > > mysql -u root -p -e "SET FOREIGN_KEY_CHECKS=0;" < /tmp/dump.sql > > > > Does the InnoDB engine set the foreign key checks back to 1 again, > automatically - once the database install is complete? Under what > circumstances one can get into trouble if the FK check is not set back > to 1 at the end of the transaction? Is there a white paper I can read > on the subject since I cannot find anything? > > > > Is there a way to check whether the FK check is turned ON/OF? > > > > Thanks you MUCH in advance and GOOD LUCK in your new Oracle adventure! > > > > Noga Woronoff > > Interactive Constructs, Inc. > > 200 Boston Ave. Suite #1800 > > Medford, MA 02155 > > -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]