• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

role of ejbSelect methods

 
vishwak rajgopalan
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I am a newcomer to EJB. I have to use CMR on one of my projects.I have a question regarding the use of ejbSelect methods in a CMR. I have two entity beans StudentEJB and CourseEJB which have a M:N relationship with each other with the studentId variable of StudentEJB being related to the courseNo variable of CourseEJB. Can ejbSelect methods be used to determine in such a case the courses that a student is enrolled in instead of using session tracking to track the student's id and then retrieve the courses based on studentId.
Could some please help me in this regard
Thanks,
Vishwak
 
Karthik Guru
Ranch Hand
Posts: 1209
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I didnt get the session tracking part that you referred to.
As long as data is persisted to the repository, you can get all courses for a given student.
If you have an access to the StudentEJb, you dont need a ejbSelect to get all the courses.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic