You are viewing a plain text version of this content. The canonical link for it is here.
Posted to ojb-user@db.apache.org by Fernando <fe...@ptcom.com.br> on 2004/09/01 20:19:24 UTC

Error trying to filter a class...

Hi everybody,
I'm having a problem when trying do filter a UsuarioVO ByPrimaryKey. I wrote the repository.xml from tha classes used and the error.
Sorry for the large email, really sorry.... But I have to solve this, thanks, really thanks for your time.

Erro:
15:02:27,413 INFO  [STDOUT] Error while iterate ResultSet for query org.apache.ojb.broker.accesslayer.RsQueryObject[query: Query from class br.com.ptcom.webField.model.UsuarioVO where [cdCgcCpf = 1, tpPessoa = f, cdUsuario = 10], class descriptor: br.com.ptcom.webField.model.UsuarioVO]
15:02:27,413 INFO  [STDOUT] Can't generate primary key values for given Identity br.com.ptcom.webField.model.PessoaVO{1}
15:02:27,413 ERROR [STDERR] org.apache.ojb.broker.PersistenceBrokerException: Can't generate primary key values for given Identity br.com.ptcom.webField.model.PessoaVO{1}

<class-descriptor class="br.com.ptcom.webField.model.PessoaVO" table="LAB.PESSOA" >
  <field-descriptor id="0"
    name="cdCgcCpf"
    column="CD_CGC_CPF"
    jdbc-type="INTEGER"
    primarykey="true"
  />
  <field-descriptor id="1"
    name="tpPessoa"
    column="TP_PESSOA"
    jdbc-type="VARCHAR"
    primarykey="true"
  />
  <field-descriptor id="2"
    name="cdPais"
    column="CD_PAIS"
    jdbc-type="INTEGER"
  />
  <reference-descriptor 
    name="paisVO"
    class-ref="br.com.ptcom.webField.model.PaisVO"
    auto-retrieve="true"
    >
   <foreignkey field-ref="cdPais"/>
  </reference-descriptor>
  
  <field-descriptor id="3"
    name="cdEstado"
    column="CD_ESTADO"
    jdbc-type="INTEGER"
  />
  <reference-descriptor 
    name="estadoVO"
    class-ref="br.com.ptcom.webField.model.EstadoVO"
    auto-retrieve="true"
    >
   <foreignkey field-ref="cdEstado"/>
  </reference-descriptor>
  
  <field-descriptor id="4"
    name="cdMunicipio"
    column="CD_MUNICIPIO"
    jdbc-type="INTEGER"
  />
  <reference-descriptor 
    name="municipioVO"
    class-ref="br.com.ptcom.webField.model.MunicipioVO"
    auto-retrieve="true"
    >
   <foreignkey field-ref="cdMunicipio"/>
  </reference-descriptor>
</class-descriptor>



class-descriptor class="br.com.ptcom.webField.model.GrupoAplicacaoVO" table="LAB.GRUPO_APLICACAO" >
  <field-descriptor id="0"
    name="cdGrupo"
    column="CD_GRUPO"
    jdbc-type="VARCHAR"
    primarykey="true"
  />
  <collection-descriptor
 name="usuariosGrupoAplicacao"
 collection-class="org.apache.ojb.broker.util.collections.ManageableArrayList"
 element-class-ref="br.com.ptcom.webField.model.UsuarioVO"
 auto-retrieve="false"
 auto-delete="false"
 auto-update="false"
 indirection-table="LAB.USUARIO_GRUPO_APLICACAO"
   >
   <fk-pointing-to-this-class column="CD_GRUPO"/>
   <fk-pointing-to-element-class column="CD_CGC_CPF"/>
   <fk-pointing-to-element-class column="TP_PESSOA"/>
   <fk-pointing-to-element-class column="CD_USUARIO"/>
  </collection-descriptor>
  
  <collection-descriptor 
    name="subAcoesGrupo"
    element-class-ref="br.com.ptcom.webField.model.SubAcaoUsuarioGrupoVO"
    auto-update="true"
    auto-delete="true"   
    auto-insert="true"  
    auto-retrieve="true"
  >
  <inverse-foreignkey field-ref="cdGrupo"/>
  </collection-descriptor>
</class-descriptor>

<class-descriptor class="br.com.ptcom.webField.model.UsuarioVO" table="LAB.USUARIO" >
  <field-descriptor id="2"
    name="cdUsuario"
    column="CD_USUARIO"
    jdbc-type="VARCHAR"
    primarykey="true"
  />
  <field-descriptor id="0"
    name="cdCgcCpf"
    column="CD_CGC_CPF"
    jdbc-type="INTEGER"
    primarykey="true"
  />
  <reference-descriptor 
    name="pessoaVO"
    class-ref="br.com.ptcom.webField.model.PessoaVO"
    auto-retrieve="true"
    >
   <foreignkey field-ref="cdCgcCpf"/>
  </reference-descriptor>
  
  <field-descriptor id="1"
    name="tpPessoa"
    column="TP_PESSOA"
    jdbc-type="VARCHAR"
    primarykey="true"
  />  
  
  <collection-descriptor
 name="usuariosGrupoAplicacao"
 collection-class="org.apache.ojb.broker.util.collections.ManageableArrayList"
 element-class-ref="br.com.ptcom.webField.model.GrupoAplicacaoVO"
 auto-retrieve="false"
 auto-delete="false"
 auto-update="false"
 indirection-table="LAB.USUARIO_GRUPO_APLICACAO"
   >
   <fk-pointing-to-this-class column="CD_CGC_CPF"/>
   <fk-pointing-to-this-class column="TP_PESSOA"/>
   <fk-pointing-to-this-class column="CD_USUARIO"/>
   <fk-pointing-to-element-class column="CD_GRUPO"/>
  </collection-descriptor>

</class-descriptor>




Re: Error trying to filter a class...

Posted by Fernando Bernardino <fe...@ptcom.com.br>.
THANKS!!!!!!!! One of the problems is out now! Really thanks!
I'm thinking there will be more emails soon. Thanks for your time and help!!

Fernando Bernardino
.COM Tecnology

----- Original Message -----
From: "Armin Waibel" <ar...@apache.org>
To: "OJB Users List" <oj...@db.apache.org>
Sent: Friday, September 03, 2004 3:52 PM
Subject: Re: Error trying to filter a class...


> Hi again,
>
>  > PAIS(cod pk)
>  > ESTADO(cod_estado pk, cod_pais pk/fk)
>  > MUNICIPIO(cod_municipio pk, cod_estado pk/fk, cod_pais pk/fk)
>
> In MUNICIPIO you declare a 1:1 reference to ESTADO. ESTADO use an
> composed PK, thus you need two FK fields in MUNICIPIO to identify an
> ESTADO object.
>
> <reference-descriptor
>  >     name="estadoVO"
>  >     class-ref="br.com.ptcom.webField.model.EstadoVO"
>  >     auto-retrieve="true"
>  >     >
>  >    <foreignkey field-ref="cdEstado"/>
> ==>     <foreignkey field-ref="cod_pais"/>
>  >   </reference-descriptor>
>
> + an field-descriptor for 'cod_pais' in MUNICIPIO.
>
> If you use composed PK (several PK fields in class-descriptor), then OJB
> assume that the object is only unique across the declared PK fields. If
> you reference such an object, you have to declare all PK fields as FK
> fields.
>
> regards,
> Armin



---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-user-help@db.apache.org


Re: Error trying to filter a class...

Posted by Armin Waibel <ar...@apache.org>.
Hi again,

 > PAIS(cod pk)
 > ESTADO(cod_estado pk, cod_pais pk/fk)
 > MUNICIPIO(cod_municipio pk, cod_estado pk/fk, cod_pais pk/fk)

In MUNICIPIO you declare a 1:1 reference to ESTADO. ESTADO use an 
composed PK, thus you need two FK fields in MUNICIPIO to identify an 
ESTADO object.

<reference-descriptor
 >     name="estadoVO"
 >     class-ref="br.com.ptcom.webField.model.EstadoVO"
 >     auto-retrieve="true"
 >     >
 >    <foreignkey field-ref="cdEstado"/>
==>     <foreignkey field-ref="cod_pais"/>
 >   </reference-descriptor>

+ an field-descriptor for 'cod_pais' in MUNICIPIO.

If you use composed PK (several PK fields in class-descriptor), then OJB 
assume that the object is only unique across the declared PK fields. If 
you reference such an object, you have to declare all PK fields as FK 
fields.

regards,
Armin



Fernando Bernardino wrote:

> Hi Armin and everybody, thanks for your time!
> I'm using OJB 1.0rc5 and Oracle 8.1.7 with JBoss3.2.3.
> So, I've removed all the "id" from field-descriptor. Thanks for the tip Armin!!!
> 
> So, my problems is: I could not filter a class named UsuarioVO, so I decided to start again... Because I have some other classes associated to UsuarioVO that are the classes I posted above. I can't filter a class named MunicipioVO so, I can't filter PessoaVO and UsuarioVO that are associated with MunicipioVO. Sorry about my english, i hope you understand....
> 
> The classes posted:
> PAIS(cod pk)
> ESTADO(cod_estado pk, cod_pais pk/fk)
> MUNICIPIO(cod_municipio pk, cod_estado pk/fk, cod_pais pk/fk)
> 
> If it helps:
> PAIS = COUNTRY
> ESTADO = STATE
> MUNICIPIO = CITY
> If I remove the primarykey="true" in the field-descriptor of a atribute that are pk and fk then my filter works!!!!!!!!! Why???? But I think this is wrong because I have this pk's in my RDBMS. The repository described above are the original, but i have removed the primarykey="true" in the described field-descriptor's:
>   EstadoVO:
>     - cdPais;
>   MunicipioVO:
>     -cdPais
>     -cdEstado
> I'll remove the pk tag to terminate this step. But I want to report, if this is a bug or it's an error from my code. Thanks for you all, really thanks!!! More emails soon.
> REPOSITORY.XML:
> 
> <class-descriptor class="br.com.ptcom.webField.model.PaisVO" table="LAB.PAIS" >
>   <field-descriptor
>     name="cdPais"
>     column="CD_PAIS"
>     jdbc-type="INTEGER"
>     primarykey="true"
>   />
>   .........
> </class-descriptor>
> 
> 
> <class-descriptor class="br.com.ptcom.webField.model.EstadoVO" table="LAB.ESTADO" >
>   <field-descriptor
>     name="cdPais"
>     column="CD_PAIS"
>     jdbc-type="INTEGER"
>     primarykey="true"
>   />
>   <reference-descriptor 
>     name="paisVO"
>     class-ref="br.com.ptcom.webField.model.PaisVO"
>     auto-retrieve="true"
>     >
>    <foreignkey field-ref="cdPais"/>
>   </reference-descriptor>
>   
>   <field-descriptor
>     name="cdEstado"
>     column="CD_ESTADO"
>     jdbc-type="INTEGER"
>     primarykey="true"
>   />
>   ........
> </class-descriptor>
> 
> 
> <class-descriptor class="br.com.ptcom.webField.model.MunicipioVO" table="LAB.MUNICIPIO" >
>   <field-descriptor
>     name="cdPais"
>     column="CD_PAIS"
>     jdbc-type="INTEGER"
>     primarykey="true"
>   />
>   <reference-descriptor 
>     name="paisVO"
>     class-ref="br.com.ptcom.webField.model.PaisVO"
>     auto-retrieve="true"
>     >
>    <foreignkey field-ref="cdPais"/>
>   </reference-descriptor>
>   
>   <field-descriptor
>     name="cdEstado"
>     column="CD_ESTADO"
>     jdbc-type="INTEGER"
>     primarykey="true"
>   />
>   <reference-descriptor 
>     name="estadoVO"
>     class-ref="br.com.ptcom.webField.model.EstadoVO"
>     auto-retrieve="true"
>     >
>    <foreignkey field-ref="cdEstado"/>
>   </reference-descriptor>
>   
>   <field-descriptor
>     name="cdMunicipio"
>     column="CD_MUNICIPIO"
>     jdbc-type="INTEGER"
>     primarykey="true"
>   />  
>   ...........
> </class-descriptor>
> 
> 
> The Error:
> 14:52:39,280 INFO  [STDOUT] [org.apache.ojb.broker.accesslayer.JdbcAccessImpl] ERROR: 
> 14:52:39,280 INFO  [STDOUT] PersistenceBrokerException during the execution of materializeObject: Can't generate primary key values for given Identity br.com.ptcom.webField.model.EstadoVO{13}
> 14:52:39,280 INFO  [STDOUT] Can't generate primary key values for given Identity br.com.ptcom.webField.model.EstadoVO{13}
> 14:52:39,327 ERROR [STDERR] org.apache.ojb.broker.PersistenceBrokerException: Can't generate primary key values for given Identity br.com.ptcom.webField.model.EstadoVO{13}
> .....
> 14:52:39,327 INFO  [STDOUT] [org.apache.ojb.broker.accesslayer.RsIterator] ERROR: 
> 14:52:39,327 INFO  [STDOUT] Error while iterate ResultSet for query org.apache.ojb.broker.accesslayer.RsQueryObject[query: Query from class br.com.ptcom.webField.model.MunicipioVO where [cdMunicipio = 1313], class descriptor: br.com.ptcom.webField.model.MunicipioVO]
> 14:52:39,327 INFO  [STDOUT] Can't generate primary key values for given Identity br.com.ptcom.webField.model.EstadoVO{13}
> 14:52:39,327 ERROR [STDERR] org.apache.ojb.broker.PersistenceBrokerException: Can't generate primary key values for given Identity br.com.ptcom.webField.model.EstadoVO{13}
> .....
> 14:52:39,327 ERROR [STDERR] br.com.ptcom.webField.exception.DAOException: java.util.NoSuchElementException: Could not obtain next object: Can't generate primary key values for given Identity br.com.ptcom.webField.model.EstadoVO{13}
> 
> 
> 
> 
>>Hi again,
>>
>>first try to remove the 'id' attributes from the field-descriptor 
>>(assume since rc1 they are no longer needed and this may cause an 
>>side-effect).
>>
>> > 15:02:27,413 INFO  [STDOUT] Can't generate primary key values for 
>>given Identity br.com.ptcom.webField.model.PessoaVO{1}
>>
>>The Identity object only use one PK field with value '1' instead of two 
>>fields. Don't know why this was the case.
>>If removing of 'id' attributes doesn't solve the problem, please post 
>>the source code for the query and the whole stack trace too.
>>
>>
>>regards,
>>Armin 
> 
> 
> 
> Congratulations for all the community envolved in OJB, this is REALLY GOD!!!!!!!!! I' love it.
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-user-help@db.apache.org


Re: Error trying to filter a class...

Posted by Fernando Bernardino <fe...@ptcom.com.br>.
Hi Armin and everybody, thanks for your time!
I'm using OJB 1.0rc5 and Oracle 8.1.7 with JBoss3.2.3.
So, I've removed all the "id" from field-descriptor. Thanks for the tip Armin!!!

So, my problems is: I could not filter a class named UsuarioVO, so I decided to start again... Because I have some other classes associated to UsuarioVO that are the classes I posted above. I can't filter a class named MunicipioVO so, I can't filter PessoaVO and UsuarioVO that are associated with MunicipioVO. Sorry about my english, i hope you understand....

The classes posted:
PAIS(cod pk)
ESTADO(cod_estado pk, cod_pais pk/fk)
MUNICIPIO(cod_municipio pk, cod_estado pk/fk, cod_pais pk/fk)

If it helps:
PAIS = COUNTRY
ESTADO = STATE
MUNICIPIO = CITY
If I remove the primarykey="true" in the field-descriptor of a atribute that are pk and fk then my filter works!!!!!!!!! Why???? But I think this is wrong because I have this pk's in my RDBMS. The repository described above are the original, but i have removed the primarykey="true" in the described field-descriptor's:
  EstadoVO:
    - cdPais;
  MunicipioVO:
    -cdPais
    -cdEstado
I'll remove the pk tag to terminate this step. But I want to report, if this is a bug or it's an error from my code. Thanks for you all, really thanks!!! More emails soon.
REPOSITORY.XML:

<class-descriptor class="br.com.ptcom.webField.model.PaisVO" table="LAB.PAIS" >
  <field-descriptor
    name="cdPais"
    column="CD_PAIS"
    jdbc-type="INTEGER"
    primarykey="true"
  />
  .........
</class-descriptor>


<class-descriptor class="br.com.ptcom.webField.model.EstadoVO" table="LAB.ESTADO" >
  <field-descriptor
    name="cdPais"
    column="CD_PAIS"
    jdbc-type="INTEGER"
    primarykey="true"
  />
  <reference-descriptor 
    name="paisVO"
    class-ref="br.com.ptcom.webField.model.PaisVO"
    auto-retrieve="true"
    >
   <foreignkey field-ref="cdPais"/>
  </reference-descriptor>
  
  <field-descriptor
    name="cdEstado"
    column="CD_ESTADO"
    jdbc-type="INTEGER"
    primarykey="true"
  />
  ........
</class-descriptor>


<class-descriptor class="br.com.ptcom.webField.model.MunicipioVO" table="LAB.MUNICIPIO" >
  <field-descriptor
    name="cdPais"
    column="CD_PAIS"
    jdbc-type="INTEGER"
    primarykey="true"
  />
  <reference-descriptor 
    name="paisVO"
    class-ref="br.com.ptcom.webField.model.PaisVO"
    auto-retrieve="true"
    >
   <foreignkey field-ref="cdPais"/>
  </reference-descriptor>
  
  <field-descriptor
    name="cdEstado"
    column="CD_ESTADO"
    jdbc-type="INTEGER"
    primarykey="true"
  />
  <reference-descriptor 
    name="estadoVO"
    class-ref="br.com.ptcom.webField.model.EstadoVO"
    auto-retrieve="true"
    >
   <foreignkey field-ref="cdEstado"/>
  </reference-descriptor>
  
  <field-descriptor
    name="cdMunicipio"
    column="CD_MUNICIPIO"
    jdbc-type="INTEGER"
    primarykey="true"
  />  
  ...........
</class-descriptor>


The Error:
14:52:39,280 INFO  [STDOUT] [org.apache.ojb.broker.accesslayer.JdbcAccessImpl] ERROR: 
14:52:39,280 INFO  [STDOUT] PersistenceBrokerException during the execution of materializeObject: Can't generate primary key values for given Identity br.com.ptcom.webField.model.EstadoVO{13}
14:52:39,280 INFO  [STDOUT] Can't generate primary key values for given Identity br.com.ptcom.webField.model.EstadoVO{13}
14:52:39,327 ERROR [STDERR] org.apache.ojb.broker.PersistenceBrokerException: Can't generate primary key values for given Identity br.com.ptcom.webField.model.EstadoVO{13}
.....
14:52:39,327 INFO  [STDOUT] [org.apache.ojb.broker.accesslayer.RsIterator] ERROR: 
14:52:39,327 INFO  [STDOUT] Error while iterate ResultSet for query org.apache.ojb.broker.accesslayer.RsQueryObject[query: Query from class br.com.ptcom.webField.model.MunicipioVO where [cdMunicipio = 1313], class descriptor: br.com.ptcom.webField.model.MunicipioVO]
14:52:39,327 INFO  [STDOUT] Can't generate primary key values for given Identity br.com.ptcom.webField.model.EstadoVO{13}
14:52:39,327 ERROR [STDERR] org.apache.ojb.broker.PersistenceBrokerException: Can't generate primary key values for given Identity br.com.ptcom.webField.model.EstadoVO{13}
.....
14:52:39,327 ERROR [STDERR] br.com.ptcom.webField.exception.DAOException: java.util.NoSuchElementException: Could not obtain next object: Can't generate primary key values for given Identity br.com.ptcom.webField.model.EstadoVO{13}



> Hi again,
> 
> first try to remove the 'id' attributes from the field-descriptor 
> (assume since rc1 they are no longer needed and this may cause an 
> side-effect).
> 
>  > 15:02:27,413 INFO  [STDOUT] Can't generate primary key values for 
> given Identity br.com.ptcom.webField.model.PessoaVO{1}
> 
> The Identity object only use one PK field with value '1' instead of two 
> fields. Don't know why this was the case.
> If removing of 'id' attributes doesn't solve the problem, please post 
> the source code for the query and the whole stack trace too.
> 
> 
> regards,
> Armin 


Congratulations for all the community envolved in OJB, this is REALLY GOD!!!!!!!!! I' love it.

Re: Error trying to filter a class...

Posted by Armin Waibel <ar...@apache.org>.
Hi again,

first try to remove the 'id' attributes from the field-descriptor 
(assume since rc1 they are no longer needed and this may cause an 
side-effect).

 > 15:02:27,413 INFO  [STDOUT] Can't generate primary key values for 
given Identity br.com.ptcom.webField.model.PessoaVO{1}

The Identity object only use one PK field with value '1' instead of two 
fields. Don't know why this was the case.
If removing of 'id' attributes doesn't solve the problem, please post 
the source code for the query and the whole stack trace too.


regards,
Armin


Fernando wrote:

> Hi everybody,
> I'm having a problem when trying do filter a UsuarioVO ByPrimaryKey. I wrote the repository.xml from tha classes used and the error.
> Sorry for the large email, really sorry.... But I have to solve this, thanks, really thanks for your time.
> 
> Erro:
> 15:02:27,413 INFO  [STDOUT] Error while iterate ResultSet for query org.apache.ojb.broker.accesslayer.RsQueryObject[query: Query from class br.com.ptcom.webField.model.UsuarioVO where [cdCgcCpf = 1, tpPessoa = f, cdUsuario = 10], class descriptor: br.com.ptcom.webField.model.UsuarioVO]
> 15:02:27,413 INFO  [STDOUT] Can't generate primary key values for given Identity br.com.ptcom.webField.model.PessoaVO{1}
> 15:02:27,413 ERROR [STDERR] org.apache.ojb.broker.PersistenceBrokerException: Can't generate primary key values for given Identity br.com.ptcom.webField.model.PessoaVO{1}
> 
> <class-descriptor class="br.com.ptcom.webField.model.PessoaVO" table="LAB.PESSOA" >
>   <field-descriptor id="0"
>     name="cdCgcCpf"
>     column="CD_CGC_CPF"
>     jdbc-type="INTEGER"
>     primarykey="true"
>   />
>   <field-descriptor id="1"
>     name="tpPessoa"
>     column="TP_PESSOA"
>     jdbc-type="VARCHAR"
>     primarykey="true"
>   />
>   <field-descriptor id="2"
>     name="cdPais"
>     column="CD_PAIS"
>     jdbc-type="INTEGER"
>   />
>   <reference-descriptor 
>     name="paisVO"
>     class-ref="br.com.ptcom.webField.model.PaisVO"
>     auto-retrieve="true"
>     >
>    <foreignkey field-ref="cdPais"/>
>   </reference-descriptor>
>   
>   <field-descriptor id="3"
>     name="cdEstado"
>     column="CD_ESTADO"
>     jdbc-type="INTEGER"
>   />
>   <reference-descriptor 
>     name="estadoVO"
>     class-ref="br.com.ptcom.webField.model.EstadoVO"
>     auto-retrieve="true"
>     >
>    <foreignkey field-ref="cdEstado"/>
>   </reference-descriptor>
>   
>   <field-descriptor id="4"
>     name="cdMunicipio"
>     column="CD_MUNICIPIO"
>     jdbc-type="INTEGER"
>   />
>   <reference-descriptor 
>     name="municipioVO"
>     class-ref="br.com.ptcom.webField.model.MunicipioVO"
>     auto-retrieve="true"
>     >
>    <foreignkey field-ref="cdMunicipio"/>
>   </reference-descriptor>
> </class-descriptor>
> 
> 
> 
> class-descriptor class="br.com.ptcom.webField.model.GrupoAplicacaoVO" table="LAB.GRUPO_APLICACAO" >
>   <field-descriptor id="0"
>     name="cdGrupo"
>     column="CD_GRUPO"
>     jdbc-type="VARCHAR"
>     primarykey="true"
>   />
>   <collection-descriptor
>  name="usuariosGrupoAplicacao"
>  collection-class="org.apache.ojb.broker.util.collections.ManageableArrayList"
>  element-class-ref="br.com.ptcom.webField.model.UsuarioVO"
>  auto-retrieve="false"
>  auto-delete="false"
>  auto-update="false"
>  indirection-table="LAB.USUARIO_GRUPO_APLICACAO"
>    >
>    <fk-pointing-to-this-class column="CD_GRUPO"/>
>    <fk-pointing-to-element-class column="CD_CGC_CPF"/>
>    <fk-pointing-to-element-class column="TP_PESSOA"/>
>    <fk-pointing-to-element-class column="CD_USUARIO"/>
>   </collection-descriptor>
>   
>   <collection-descriptor 
>     name="subAcoesGrupo"
>     element-class-ref="br.com.ptcom.webField.model.SubAcaoUsuarioGrupoVO"
>     auto-update="true"
>     auto-delete="true"   
>     auto-insert="true"  
>     auto-retrieve="true"
>   >
>   <inverse-foreignkey field-ref="cdGrupo"/>
>   </collection-descriptor>
> </class-descriptor>
> 
> <class-descriptor class="br.com.ptcom.webField.model.UsuarioVO" table="LAB.USUARIO" >
>   <field-descriptor id="2"
>     name="cdUsuario"
>     column="CD_USUARIO"
>     jdbc-type="VARCHAR"
>     primarykey="true"
>   />
>   <field-descriptor id="0"
>     name="cdCgcCpf"
>     column="CD_CGC_CPF"
>     jdbc-type="INTEGER"
>     primarykey="true"
>   />
>   <reference-descriptor 
>     name="pessoaVO"
>     class-ref="br.com.ptcom.webField.model.PessoaVO"
>     auto-retrieve="true"
>     >
>    <foreignkey field-ref="cdCgcCpf"/>
>   </reference-descriptor>
>   
>   <field-descriptor id="1"
>     name="tpPessoa"
>     column="TP_PESSOA"
>     jdbc-type="VARCHAR"
>     primarykey="true"
>   />  
>   
>   <collection-descriptor
>  name="usuariosGrupoAplicacao"
>  collection-class="org.apache.ojb.broker.util.collections.ManageableArrayList"
>  element-class-ref="br.com.ptcom.webField.model.GrupoAplicacaoVO"
>  auto-retrieve="false"
>  auto-delete="false"
>  auto-update="false"
>  indirection-table="LAB.USUARIO_GRUPO_APLICACAO"
>    >
>    <fk-pointing-to-this-class column="CD_CGC_CPF"/>
>    <fk-pointing-to-this-class column="TP_PESSOA"/>
>    <fk-pointing-to-this-class column="CD_USUARIO"/>
>    <fk-pointing-to-element-class column="CD_GRUPO"/>
>   </collection-descriptor>
> 
> </class-descriptor>
> 
> 
> 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-user-help@db.apache.org