0 Replies Latest reply on Feb 15, 2006 2:49 AM by giordano

    JBoss, entity beans and MySql

      Hi,

      I created a simple EJB applications using JBoss 4.0.3 and MySql 4.1. to test transaction. I created a simple table (user) with an ID (primary key), a username and a password field. Then I created an entity bean mapping the table and a session bean to manage entity bean. I tested the application creating a new user and all is working. The user is created in the database. I put a condition in my business logic: after creating a new user if the condition is true then the application must execute the rollback. I tested this second case, the application executes the rollback but when I open the database the new row is created with the pk and all other fields set to null. I think if the transaction is not executed the new row in the database should not be present. Is this normal or there is some problem?
      If there is some problem it is in JBoss or in mySql?

      Many thanks and bye,
      Giordano