What's most likely happening is that your 'BMP-style' finder is using a 
different database connection than JAWS is for CMP.

The reason behind this is that which connection jaws uses is defined in 
jaws.xml or standardjaws.xml, while your 'BMP-style' code uses a 
connection defined in a resource reference.

Does your ejb-jar.xml define a resource-reference?
You'll probably (unless your MySQL datasource is DefaultDS) need a 
jboss.xml to define a resource manager and map the resource reference to 
the resource manager.

-danch

Ray wrote:

> Hi there.
> 
> I've a set of container managed entity beans running
> on JBOSS, but I've had to define my own
> finder method:
> 
> ejbFindByCategory
> 
> which returns a collection.
> 
> The problem is that I use standard JDBC calls to pick
> up the records, but an exception is
> being thrown when I try to access the database
> (MySQL).
> 
> The message tells me that the table "art_to_cat" does
> not exist ... which it does, so you can see
> why I'm a bit confused.
> 
> Since I use the JAWS interface for database access,
> I'm thinking that perhaps I need to define the
> existence of the table somehow. It's used as a link
> table in a many-to-many relationship, so I 
> haven't actually defined an entity bean to access it.
> 
> Do I need to do this in order that it can be used in a
> query as part of a defined finder method?
> 
> Thanks in advance
> 
> 
> Ray


Confidential e-mail for addressee only.  Access to this e-mail by anyone else is 
unauthorized.
If you have received this message in error, please notify the sender immediately by 
reply e-mail 
and destroy the original communication.

Reply via email to