ALLInterview.com :: Home Page            
 Advertise your Business Here     
Browse  |   Placement Papers  |   Company  |   Code Snippets  |   Certifications  |   Visa Questions
Post Question  |   Post Answer  |   My Panel  |   Search  |   Articles  |   Topics  |   ERRORS new
   Refer this Site  Refer This Site to Your Friends  Site Map  Bookmark this Site  Set it as your HomePage  Contact Us     Login  |  Sign Up                      
Google
   
 
Categories >> Software >> Java Related >> Java J2EE >> Core Java
 
 


 

 
 Core Java interview questions  Core Java Interview Questions (1728)
 Advanced Java interview questions  Advanced Java Interview Questions (332)
 Swing interview questions  Swing Interview Questions (44)
 EJB interview questions  EJB Interview Questions (134)
 Servlets interview questions  Servlets Interview Questions (255)
 Struts interview questions  Struts Interview Questions (196)
 JDBC interview questions  JDBC Interview Questions (187)
 JMS interview questions  JMS Interview Questions (9)
 SunOne interview questions  SunOne Interview Questions (3)
 J2EE interview questions  J2EE Interview Questions (71)
 Weblogic interview questions  Weblogic Interview Questions (147)
 Websphere interview questions  Websphere Interview Questions (14)
 Java Networking interview questions  Java Networking Interview Questions (20)
 Java J2EE AllOther interview questions  Java J2EE AllOther Interview Questions (87)
Question
What advantage does an entity bean have over a sessin bean?
 Question Submitted By :: Core-Java
I also faced this Question!!     Answer Posted By  
 
Answer
# 1
Entity Bean is a Java class which implements an Enterprise
Bean interface and provides the implementation of the
business methods. There are two types: Container Managed
Persistence (CMP) and Bean-Managed Persistence (BMP).
Session Bean is used to represent a workflow on behalf of a
client. There are two types: Stateless and Stateful.
Stateless bean is the simplest bean. It doesn't maintain any
conversational state with clients between method
invocations. Stateful bean maintains state between invocations.
 
Is This Answer Correct ?    18 Yes 5 No
Uppi
 
Answer
# 2
entity beans are generally used for database interaction
thus provide various EJB services like
transctions,persitence etc which using the seesion bean
will be manully handeled by the programmer while
interacting with Db,session beans are basically for
processing the logic not for DB entities
 
Is This Answer Correct ?    13 Yes 2 No
Tarunam Verma
 
 
 
Answer
# 3
An entity bean represents an entity such as an employer,
student, etc. A session bean is a type of EJB (Enterprise
JavaBean) that encapsulates the logic of a business process
and business rules. Entity beans offer the following
advantages over session beans:

Persistence: Entity beans are persistent, i.e., the state
of the bean exists beyond the lifetime of the application
or the application process. There are two types of
persistence: Bean-managed and Container-managed. In Bean-
managed persistence, the code contains the calls that
access the database. In Container-managed persistence, the
EJB container generates the database calls.
Shared Access: Multiple clients can share the entity beans.
It works within the transactions as the client changes the
data.
Primary Key: Each entity bean has a unique object
identifier that enables the client to locate a particular
entity bean.
Relationship: An entity bean can relate to other entity
beans. Both CMP and BMP can be used to maintain
relationships.
 
Is This Answer Correct ?    1 Yes 4 No
Gaurav
 

 
 
 
Other Core Java Interview Questions
 
  Question Asked @ Answers
 
what is dynamic method dispatch ? Fidelity 26
Explain difference between final, finally and finalize? Cognizent 3
Explain final, finalize() and finally? Accenture 11
I have a class which is abstract which contains only the abstract methods. This is similar to an interface. Then, if i have given a choice to choose one of them. Which one i have to choose and why?   4
which one is more efficient int x; 1. if(x==null) 2.if(null==x) state which one either 1 or 2? HP 6
tell me some common TCS 2
wHAT IS DEFAULT SPECIFIER IN JAVA wHAT IS DEFAULT CONSTRUCTOR IN JAVA wHAT IS DEFAULT METHOD IN JAVA IBM 12
How to call a Stored Procedure from JDBC? Satyam 4
To obtain design information about an object, which class in used?   1
what is the meaning of java.lang and java.util   6
What is "finally" keyword?   10
What is the purpose of premetive data types in java? Merrill-Lynch 2
 
For more Core Java Interview Questions Click Here 
 
 
 
 
 


   
Copyright Policy  |  Terms of Service  |  Articles  |  Site Map  |  RSS Site Map  |  Contact Us
   
Copyright 2013  ALLInterview.com.  All Rights Reserved.

ALLInterview.com   ::  KalAajKal.com