ibatis-user-cs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bob Hanson" <mnbo...@gmail.com>
Subject Re: Recursive list
Date Tue, 06 Mar 2007 14:30:02 GMT
1. GroupBy result maps do not currently support the <constructor>
element. It is ignored.
2. I recently learned from Giles that the same ResultMap cannot be
used more than once when processing a query so I don't believe you can
achieve what you're trying to do below.

On 3/6/07, Guilhem Berthalon <guilhem@aroban.com> wrote:
> Hi,
> I 've got a problem to populate recursive list :
>
> This my resultmap :
>
>        <resultMap id="ResultCategorie" class="Categorie" groupBy="ParentId">
>       <constructor>
>         <argument argumentName="intituleXML" column="CategorieIntitule"/>
>       </constructor>
>       <result property="Id" column="CategorieId"/>
>       <result property="ParentId" column="CategorieParentId"/>
>       <result property="Abreviation" column="CategorieAbreviation"/>
>       <result property="Ordre" column="CategorieOrdre"/>
>       <result property="Obsolete" column="CategorieObsolete"/>
>       <result property="DateCreation" column="CategorieDateCreation"/>
>       <result property="TimeStamp" column="CategorieTimeStamp"/>
>       <result property="CategorieList" nullValue="null"
> resultMapping="Categorie.ResultCategorie"
> notNullColumn="CategorieParentId"/>
>     </resultMap>
>
> The content of my categorie table and the result of my stored procedure
> (selectCategorie):
>
> ID      ParentID        Intitule                Abreviation
>
> 11      NULL            Autheur                 Aut
> 13      NULL            Bahut                   ba
> 9       7               Collection2006          Col2006
> 10      7               Collection2007          Col2007
> 7       NULL            Collection              Coll
>
> Have you got an idea?
> Thanks,
>
>
>
> Guilhem Berthalon
> AROBAN
> 28 rue des teinturiers
> 84 000 AVIGNON
> tel : 04 32 76 23 60
> Hotline : 04 90 85 89 29
>
>
>

Mime
View raw message