3 Replies Latest reply on Dec 13, 2002 8:24 AM by kennyl

    One CMP for one table?

    chris.chen

      Hi all,

      We use CMP in our application. Since all database operations are done by EntityBean, my question is do we need design CMP for every database table?

        • 1. Re: One CMP for one table?
          gateway87

          I think so if you want to use CMP to process your data.

          • 2. Re: One CMP for one table?
            chris.chen

            thank you

            • 3. Re: One CMP for one table?
              kennyl

              One thing to watch out for.

              If you decide to access a table through CMP/BMP, be careful if you also modify the same table through other database object (e.g. Package stored procedure ... etc.)

              If EJB container already cash a record as CMP in cache, and then you separately modify the same record outside EJB container framework (e.g. direct database update). Next time, you access the EJB of the same record, EJB might give you the old record already in cache, and the underlying persistence to changes might not be maintained.