Assuming that you are accessing the entity beans from within a stateless session bean, make the transaction attribute as 'REQUIRED' for all the beans. That way you will be accessing the CMR in the same transaction in which you acquired it in the first place.
How are you accessing the CMR? If its from within a java-bean and not an 'enteprise java bean' (SLSB for eg) then you will run into this error, because you probably are not starting a transaction before accessing the 'entity bean' in your 'java bean'. The entity bean , since it has a transaction attribute of 'required' will start a new trsnactoin. The CMR will be created in that transaction. but you are trying to access that CMR in a 'java-bean' which is NOT in the same transaction.
Enclosing the java bean method in a transaction may fix this issue
or better why dont you access the entity bean from with a SLSB facade as is the norm
i'm accessing the CMR within a java-bean and not the EJB. reason being is my jsp page is reffering to my java-bean. How can i point my jsp page to directly get the value from the EJB?
anyway, i've tried the code u given and it works!! thanks a lot.
another question is, how do i display the collection? it should consists packageId and softwareID in this.packagesSoftware.
i've done something like this but it gives me error:
pls advise. Thanks.
Post by:autobot
It is an experimental device that will make my mind that most powerful force on earth! More powerful than this tiny ad!
a bit of art, as a gift, that will fit in a stocking