2 Replies Latest reply on Dec 18, 2002 11:10 PM by fumeishi

    How to map EJB names to DB table names of my choosing?

    fumeishi Newbie

      Hello everyone, I'm a newbie.

      Can anyone tell me how to map EJB names to db table names of my choosing?

      Background:

      Using Oracle9i and JBOSS 3.0.2 to implement a J2EE Web application. Until recently, I've been using mySQL, but just started my efforts to migrate to Oracle.

      On startup, my web app creates a number of tables via JDBC. It's able to do so without a problem under mySQL, but runs into a problem with Oracle:

      java.sql.SQLException: ORA-00972: identifier is too long.

      I've since learned that this is due to a limitation of Oracle where schema objects must be <=30 characters in length. And, in fact, I have three EJBs whose names exceed that, so I'm happy to understand the nature of my problem there.

      I don't know whether or not that 30 char limit is insurmountable, but I'd like to fix the problem by designating table names of my choosing. I know that with weblogic, for example, there's an XML file (weblogic-cmp-rdbms-jar.xml) that allows me to make this kind of mapping. Can anyone tell me if there's a JBOSS equivalent?

      Thanks a lot in advance.