Problem: 
  * I have a "Group" POJO which keeps a list of its "members" (ManyToMany
relation).
  * The GroupAction class stores a list of my current groups and it has a
group field for 
     accessing information of a single group. In principle, the stucture is
very similar to the 
     PersonAction of the online tutorial.

Question: In the JSP, I iterate through the groups and print some group
information. For each group, I'd like to print the number of members. How do
I get it?  Can I access somehow members.size() in the JSP? Or am I on a
completely wrong path? 

Note: I tried a few things by try-and-error and sometimes I ended up with a
Hibernate LazyInitializationException. Now, I just don't know at what end to
continue? Is it something that 
i) can be solved simply via JSP and some expression, or 
ii) do I have to do something in the Action class, or
iii) does it go further down into the persistence layer?

Hope, my mail is not too short and you understand my problem. 
-- 
View this message in context: 
http://www.nabble.com/How-to-access-collection-fields-in-Struts2--tp16941170s2369p16941170.html
Sent from the AppFuse - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to