-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 
Author Message
 Post subject: too many queries - object graph
PostPosted: Mon Jan 05, 2009 8:50 pm 
Newbie

Joined: Sun Jan 04, 2009 3:52 pm
Posts: 2
Hi,

I am designing one survey system. Following is the details:

- One survey can have many questionpages
- One questionpage can have many questionsections
- One questionsection can have many questions
- One question can have many answers
- One answer can have many features
- One feature can have many rules

I am using many-to-one relationship and keeping bags in hbm.xml. Also using OSIV pattern to avoid n+1 select problem.

I am allowing admin to create survey, questionpages, questionsets,question,answers,features(automatically inserted) and define rules on that.

Now, I need everything when I display the page. I am using Object Graph so, I can navigate and easily display data on UI. But in this case, many queries are fired. Think one answer as one object. Then Features are associated, rules are associated etc.

I am bit confused desigining point of view. Can anyone give the suggestion on this?

Thanks,
Bhavin


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.