This question is one of optimization and improving performance:
I need to create an array of entity bean references. I already have an array
of primary keys, which I get from a direct JDBC query. I need to convert
these primary keys into entity bean references. The "obvious" way to do this
is to iterate through the array and call "findByPrimaryKey" for each of
these references. However, this results in what appears to be a wasteful
query, for every call to findByPrimary Key:
select id from my_table where id = ?
This is useless, and yet it gets called with every call to findByPrimaryKey.
The rest of the columns are only pulled in when the client actually calls
one of the get() methods on my beans:
select col1, col2, col3, ... from my_table where id = ?
So you see, I'd like to skip the calling of the first query altogether. Is
there a way I can do this with JOnAS?
By the way, these are CMP entity beans. I suspect I can get the behavior I
want with BMP, but I would like to stay CMP if at all possible (saves a lot
of work).
Thank you,
Bryan
----
To unsubscribe, send email to [EMAIL PROTECTED] and
include in the body of the message "unsubscribe jonas-users".
For general help, send email to [EMAIL PROTECTED] and
include in the body of the message "help".