posted 22 years ago
Hello Devender,
The choice between BMP and CMP is largely around
your app server requirements.
If you are going for CMP then your application server should
be more sophisticated than the requirement for a
BMP.Sophistication does not mean an ability to write queries
on it's own.It refers to a lot of other things.
Because you are not hard coding the usual SQL queries in
the CMP bean, you have the flexibilty to change the backend
It need not necessarily be an RDBMS.It can be a file server
where the records are stored in simple files.
Moreover even if you were using an RDBMS backend initially
and later on shifted to files ,you need not change any thing
in the bean class or any where else,provided your app server
is sophisticated enough to write the records into your
database irrespective of whatever type it is (RDBMS/files).So you can choose CMP if
your bean has/mayhave to write to different databases.
This is the main difference in selection in addition to things like
simplicity(CMP) and better control over the code(BMP).
Hope this helps,
Manjunath
[This message has been edited by Manjunath Subramanian (edited August 21, 2001).]