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
 

Reply via email to