Sorry you are right, NH-364 was fixed in 2.0.0.... it appear to me as
yesterday ;)btw, you know, if you have a problem with it.. test+JIRA.

An advise : let NH create your DB and than check the difference with the one
created by your self.
and please.... don't use identity!!

2009/3/18 Fernando Cruz <[email protected]>

>
> Hi, I'm good
> using version 2.0 of nhibernate and not 2.1.0. The interesting that
> I have another relationship equal to that problem that I am using
> idbag and works perfectly. I tell you my problem, I
> developing an application that will run on 3 different sgbds (Sql
> Server, Oracle and Postgres) researching and realized that the only
> way to
> achieve a relationship of "for many many (many to many) and
> that relationship that I have a field that is self-incrementável,
> only
> Oracle in that this field must involve a sequence, to obtain the
> next unique value. Well thank you so far and hope that I can
> help.
>
> On Mar 18, 3:16 pm, Dario Quintana <[email protected]>
> wrote:
> > Yes, you can talk portugues with Fabio, but in private, in this list,
> stick
> > to english please, maybe what you're saying could be help to another
> user.
> >
> > On Wed, Mar 18, 2009 at 2:59 PM, Fernando Cruz <[email protected]
> >wrote:
> >
> >
> >
> >
> >
> > > Opa Fábio, acho que posso falar com você em português. Bom estou
> > > usando a versão 2.0 do nhibernate e não a 2.1.0. O interessante que
> > > tenho outro relacionamento igual ao que estou com problema que utilizo
> > > idbag e funciona perfeitamente. Vou te falar meu problema, estou
> > > desenvolvendo uma aplicação que irá rodar em 3 sgbds diferentes (Sql
> > > Server, Oracle e Postgres) e pesquisando percebi que a única forma de
> > > realizar um relacionamento de "muitos pra muitos" (many to many) sendo
> > > que nesse relacionamento tenho um campo que é auto-incrementável, só
> > > que no Oracle preciso associar esse campo a uma sequence, para obter o
> > > próximo valor único. Bom obrigado até agora e espero que possa me
> > > ajudar.
> >
> > > On Mar 18, 2:05 pm, Fabio Maulo <[email protected]> wrote:
> > > > support of identity for <idbag> is pretty new in NH2.1.0Alpha1
> (Hibernate
> > > > don't supports it).BTW what is strange in your mapping is the type of
> the
> > > ID
> > > > for the collection.
> > > > If you can recreate the issue please use the JIRA attaching a test.
> > > > Thanks.
> >
> > > > 2009/3/18 Fernando Cruz <[email protected]>
> >
> > > > > Yes, use Sql Server 2005.
> >
> > > > > On Mar 18, 1:05 pm, Fabio Maulo <[email protected]> wrote:
> > > > > > RDBMS ?
> > > > > > 2009/3/18 Fernando Cruz <[email protected]>
> >
> > > > > > > I am using idbag (because I then user sequence) and has the
> > > following
> > > > > > > relationship: functionality ->> Permission <<- Profile. Here is
> the
> > > > > > > mapping of the Feature table:
> > > > > > > <?xml version="1.0" encoding="utf-8" ?>
> > > > > > > <hibernate-mapping xmlns="urn:nhibernate-mapping-2.2" default-
> > > > > > > lazy="true" assembly="ObjetoXP">
> > > > > > >    <class name="ObjetoXP.SeguFuncionalidade,ObjetoXP"
> > > > > > > table="tb_segu_funcionalidade" lazy="true">
> > > > > > >        <!-- Chaves Primarias -->
> > > > > > >        <id name="Id" column="flde_ch_funcionalidade"
> > > type="Decimal">
> > > > > > >            <generator class="native"/>
> > > > > > >        </id>
> >
> > > > > > >        <!-- Chaves estrangeiras n-1-->
> > > > > > >        <many-to-one name="Modulo" column="modu_ch_modulo"
> > > > > > > class="ObjetoXP.SeguModulo,ObjetoXP" not-null="true" />
> > > > > > >        <!-- Propriedades -->
> > > > > > >        <property column="flde_tx_descricao" type="String"
> > > > > > > name="Descricao" not-null="true" />
> >
> > > > > > >        <!-- Relações 1-N-->
> > > > > > >        <set name="ListaObjc" inverse="true" cascade="all"
> > > > > > > lazy="true">
> > > > > > >            <key column="flde_ch_funcionalidade"/>
> > > > > > >            <one-to-many
> class="ObjetoXP.SeguObjetoFunc,ObjetoXP" />
> > > > > > >        </set>
> >
> > > > > > >        <idbag name="ListaFuncPerm" table="tb_segu_permissao"
> > > > > > > lazy="true" cascade="all" inverse="false">
> > > > > > >            <collection-id column="perm_ch_permissao"
> > > type="Decimal">
> > > > > > >                <generator class="native"></generator>
> > > > > > >            </collection-id>
> > > > > > >            <key column="flde_ch_funcionalidade" />
> > > > > > >            <many-to-many class="ObjetoXP.SeguPerfil,ObjetoXP"
> > > > > > > column="perf_ch_perfil"  outer-join="true"/>
> > > > > > >        </idbag>
> >
> > > > > > >    </class>
> > > > > > > </hibernate-mapping>
> >
> > > > > > > Precisely the idbag not working properly. I try to insert two
> > > elements
> > > > > > > from the feature list and only insert a ListaFuncPerm. The
> > > interesting
> > > > > > > thing is that if I use the bag with mapping works correctly.
> >
> > > > > > --
> > > > > > Fabio Maulo
> >
> > > > --
> > > > Fabio Maulo
> >
> > --
> > Dario Quintanahttp://darioquintana.com.ar
> >
>


-- 
Fabio Maulo

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"nhusers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/nhusers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to