More Efficient to Create New Bean or Use Existing Ones

I have two beans, lets say HomeBean and OfficeBean which are related to each other by a user_id which comes from a database.

When users do a search for something I want only parts from each bean like HomeBean.city and OfficeBean.city and a few other fields from each.

I'm wondering if it is more effiecient to create a new bean, such as SearchResultBean which contains only the information that I need, or is it better to use the beans I already have? I'm pretty sure the J2EE blueprints would not agree with me making new beans, but I don't want to load all that extra information from the database when I'm not going to show it to the user.

Thanks in advance!

[698 byte] By [bryanwclark] at [2007-9-26 3:09:15]
# 1

So far I can only find this article from JAVAWORLD and it's not really geared towards my question.

http://www.javaworld.com/javaworld/jw-11-1999/jw-11-cleanbeans.html

Otherwise I'm not sure what to do, create a SearchResultBean that would contain only the data I need to return to the user after their search, or use the entire beans of which I only need less than half their information.

bryanwclark at 2007-6-29 11:14:47 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...