2 Replies Latest reply on Mar 2, 2005 6:11 PM by ittoronto

    table not found problem with mysql

    ittoronto

      Hi,

      I am trying to use MySql as database resource and find a "Table not found" problem.

      I installed "mysql-connector-java-3.1.7-bin.jar" instead of "mysql-connector-java-3.0.15-ga-bin.jar" of "Getting Started with JBoss 4.0". I am not sure if this make different.

      I deployed an simple EJB application (savingsaccount from sun with a JSP web component) and start Jboss server. Everything is fine and I can see the JNDI name of MySql database at the Jboss console. So, I guess the database is connected and the JNDI name is bound.

      When I input the user ID and enter, I met this problem:

      'javax.ejb.EJBException: ejbFindByPrimaryKey: Table not found: SAVINGSACCOUNT in statement [select....'

      Defintely, I created the table and populated with some dummy data from MySql client console. I have done with HSQL. There is no problem.

      Anyone has any clue for this problem?


      Thanks in advance.





        • 1. Re: table not found problem with mysql
          fbiaggi

          Hi,
          I just replaced mysql-connector-java-3.1.7-bin.jar with the old one 3.1.6 due to very stange problems....
          Maybe helps.

          • 2. Re: table not found problem with mysql
            ittoronto

            Thanks fbiaggi,

            That was what I had thought. I had change the Coonector/J to 'mysql-connector-java-3.0.16-ga-bin.jar' and the problem was still the same. This problem is weird as it seems there is no problem to connect to the MySql server and no problem of finding the database, but the table. The table and records are there, I can see them from the client console of MySql. While, any clue are welcome.

            Thanks.