ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Chris Lamey <cla...@localmatters.com>
Subject RE: Populating existing beans...
Date Tue, 12 Sep 2006 21:21:37 GMT
On Tue, 2006-09-12 at 13:49 -0700, Daniel Pitts wrote:
> To clarify more,
> I have a bunch of beans of different classes.  There is a table for
> each class of bean, with columns that correspond directly to bean
> properties. This makes it easy to do things like <select
> id="getAuthors" resultClass="author">SELECT * from authors</select>
>  
> What I'd like to do is something like
> <select id="getSomething" resultClass="$resultClass$"
> remapResults="true">SELECT * FROM $table$</select>

Could you use a map as a resultClass and based on what you pass in as
$table$, populate your bean?

Cheers,
Chris

Mime
View raw message