From: NHibernate J. <mik...@us...> - 2006-11-27 10:02:31
|
Duplicate column names should generate NH exception, not ADO.NET ---------------------------------------------------------------- Key: NH-823 URL: http://jira.nhibernate.org/browse/NH-823 Project: NHibernate Type: Bug Versions: 1.2.0.Beta2 =20 Reporter: Andr=C3=A9s G. Aragoneses Priority: Trivial I have found that, if you have a mapping with duplicated name properties, s= uch: <hibernate-mapping xmlns=3D"urn:nhibernate-mapping-2.0" default-lazy=3D"tru= e"> <class name=3D"Language, DataModel" table=3D"IRM_LANGUAGES" dynamic-update=3D"true"> <id name=3D"IdLanguage" column=3D"IdLanguage" unsaved-value=3D"0"> <generator class=3D"native" /> </id> <many-to-one name=3D"Type" column=3D"IdLanguage" not-null=3D"true" /> </class> </hibernate-mapping> Here, there is a typo because the column of the many-to-one tag is the same= as the column of the ID. We have found that, in this case, instead of warn= ing the user about the wrong mapping file, the exception is thrown when the= query is sent to the database. --=20 This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.nhibernate.org/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: NHibernate J. <mik...@us...> - 2006-12-05 14:00:35
|
[ http://jira.nhibernate.org/browse/NH-823?page=3Dall ] Sergey Koshcheyev updated NH-823: --------------------------------- Fix Version: 1.2.0.Beta3 Component: Core > Duplicate column names should generate NH exception, not ADO.NET > ---------------------------------------------------------------- > > Key: NH-823 > URL: http://jira.nhibernate.org/browse/NH-823 > Project: NHibernate > Type: Bug > Components: Core > Versions: 1.2.0.Beta2 > Reporter: Andr=C3=A9s G. Aragoneses > Priority: Trivial > Fix For: 1.2.0.Beta3 > > I have found that, if you have a mapping with duplicated name properties,= such: > <hibernate-mapping xmlns=3D"urn:nhibernate-mapping-2.0" default-lazy=3D"t= rue"> > <class name=3D"Language, DataModel" table=3D"IRM_LANGUAGES" > dynamic-update=3D"true"> > <id name=3D"IdLanguage" column=3D"IdLanguage" unsaved-value=3D"0"> > <generator class=3D"native" /> > </id> > <many-to-one name=3D"Type" column=3D"IdLanguage" not-null=3D"true" /> > </class> > </hibernate-mapping> > Here, there is a typo because the column of the many-to-one tag is the sa= me as the column of the ID. We have found that, in this case, instead of wa= rning the user about the wrong mapping file, the exception is thrown when t= he query is sent to the database. --=20 This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.nhibernate.org/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: NHibernate J. <mik...@us...> - 2007-01-02 13:32:27
|
[ http://jira.nhibernate.org/browse/NH-823?page=3Dcomments#action_1470= 2 ] =20 Sergey Koshcheyev commented on NH-823: -------------------------------------- The check was there before but was removed since H3 doesn't do it. I don't = remember the reason now, need to investigate further. > Duplicate column names should generate NH exception, not ADO.NET > ---------------------------------------------------------------- > > Key: NH-823 > URL: http://jira.nhibernate.org/browse/NH-823 > Project: NHibernate > Type: Bug > Components: Core > Versions: 1.2.0.Beta2 > Reporter: Andr=C3=A9s G. Aragoneses > Priority: Trivial > Fix For: 1.2.0.Beta3 > > I have found that, if you have a mapping with duplicated name properties,= such: > <hibernate-mapping xmlns=3D"urn:nhibernate-mapping-2.0" default-lazy=3D"t= rue"> > <class name=3D"Language, DataModel" table=3D"IRM_LANGUAGES" > dynamic-update=3D"true"> > <id name=3D"IdLanguage" column=3D"IdLanguage" unsaved-value=3D"0"> > <generator class=3D"native" /> > </id> > <many-to-one name=3D"Type" column=3D"IdLanguage" not-null=3D"true" /> > </class> > </hibernate-mapping> > Here, there is a typo because the column of the many-to-one tag is the sa= me as the column of the ID. We have found that, in this case, instead of wa= rning the user about the wrong mapping file, the exception is thrown when t= he query is sent to the database. --=20 This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.nhibernate.org/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: NHibernate J. <mik...@us...> - 2007-01-02 17:06:29
|
[ http://jira.nhibernate.org/browse/NH-823?page=3Dcomments#action_1470= 3 ] =20 Ayende Rahien commented on NH-823: ---------------------------------- There are valid reasons to want to map the same column to different propert= ies. Usually this is a case where the id of an object is meaningful. For instance, you may have Employee assoication, but also EmployeeId proper= ty. > Duplicate column names should generate NH exception, not ADO.NET > ---------------------------------------------------------------- > > Key: NH-823 > URL: http://jira.nhibernate.org/browse/NH-823 > Project: NHibernate > Type: Bug > Components: Core > Versions: 1.2.0.Beta2 > Reporter: Andr=C3=A9s G. Aragoneses > Priority: Trivial > Fix For: 1.2.0.Beta3 > > I have found that, if you have a mapping with duplicated name properties,= such: > <hibernate-mapping xmlns=3D"urn:nhibernate-mapping-2.0" default-lazy=3D"t= rue"> > <class name=3D"Language, DataModel" table=3D"IRM_LANGUAGES" > dynamic-update=3D"true"> > <id name=3D"IdLanguage" column=3D"IdLanguage" unsaved-value=3D"0"> > <generator class=3D"native" /> > </id> > <many-to-one name=3D"Type" column=3D"IdLanguage" not-null=3D"true" /> > </class> > </hibernate-mapping> > Here, there is a typo because the column of the many-to-one tag is the sa= me as the column of the ID. We have found that, in this case, instead of wa= rning the user about the wrong mapping file, the exception is thrown when t= he query is sent to the database. --=20 This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.nhibernate.org/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: NHibernate J. <mik...@us...> - 2007-01-02 18:46:29
|
[ http://jira.nhibernate.org/browse/NH-823?page=3Dcomments#action_1470= 4 ] =20 Sergey Koshcheyev commented on NH-823: -------------------------------------- Yes, the check was only done for columns that didn't have insert=3D"false" = update=3D"false". > Duplicate column names should generate NH exception, not ADO.NET > ---------------------------------------------------------------- > > Key: NH-823 > URL: http://jira.nhibernate.org/browse/NH-823 > Project: NHibernate > Type: Bug > Components: Core > Versions: 1.2.0.Beta2 > Reporter: Andr=C3=A9s G. Aragoneses > Priority: Trivial > Fix For: 1.2.0.Beta3 > > I have found that, if you have a mapping with duplicated name properties,= such: > <hibernate-mapping xmlns=3D"urn:nhibernate-mapping-2.0" default-lazy=3D"t= rue"> > <class name=3D"Language, DataModel" table=3D"IRM_LANGUAGES" > dynamic-update=3D"true"> > <id name=3D"IdLanguage" column=3D"IdLanguage" unsaved-value=3D"0"> > <generator class=3D"native" /> > </id> > <many-to-one name=3D"Type" column=3D"IdLanguage" not-null=3D"true" /> > </class> > </hibernate-mapping> > Here, there is a typo because the column of the many-to-one tag is the sa= me as the column of the ID. We have found that, in this case, instead of wa= rning the user about the wrong mapping file, the exception is thrown when t= he query is sent to the database. --=20 This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.nhibernate.org/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: NHibernate J. <mik...@us...> - 2007-01-08 14:34:29
|
[ http://jira.nhibernate.org/browse/NH-823?page=3Dall ] Sergey Koshcheyev updated NH-823: --------------------------------- Fix Version: (was: 1.2.0.Beta3) LATER Priority: Minor (was: Trivial) type: New Feature (was: Bug) Changing this to a feature request and delaying. > Duplicate column names should generate NH exception, not ADO.NET > ---------------------------------------------------------------- > > Key: NH-823 > URL: http://jira.nhibernate.org/browse/NH-823 > Project: NHibernate > Type: New Feature > Components: Core > Versions: 1.2.0.Beta2 > Reporter: Andr=C3=A9s G. Aragoneses > Priority: Minor > Fix For: LATER > > I have found that, if you have a mapping with duplicated name properties,= such: > <hibernate-mapping xmlns=3D"urn:nhibernate-mapping-2.0" default-lazy=3D"t= rue"> > <class name=3D"Language, DataModel" table=3D"IRM_LANGUAGES" > dynamic-update=3D"true"> > <id name=3D"IdLanguage" column=3D"IdLanguage" unsaved-value=3D"0"> > <generator class=3D"native" /> > </id> > <many-to-one name=3D"Type" column=3D"IdLanguage" not-null=3D"true" /> > </class> > </hibernate-mapping> > Here, there is a typo because the column of the many-to-one tag is the sa= me as the column of the ID. We have found that, in this case, instead of wa= rning the user about the wrong mapping file, the exception is thrown when t= he query is sent to the database. --=20 This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.nhibernate.org/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: NHibernate J. <mik...@us...> - 2007-01-08 15:12:34
|
[ http://jira.nhibernate.org/browse/NH-823?page=3Dcomments#action_1473= 4 ] =20 Andr=C3=A9s G. Aragoneses commented on NH-823: ----------------------------------------- Emmm. I don't understand then. If Ayende states that it might be possible t= o duplicate properties, why don't you close the issue? > Duplicate column names should generate NH exception, not ADO.NET > ---------------------------------------------------------------- > > Key: NH-823 > URL: http://jira.nhibernate.org/browse/NH-823 > Project: NHibernate > Type: New Feature > Components: Core > Versions: 1.2.0.Beta2 > Reporter: Andr=C3=A9s G. Aragoneses > Priority: Minor > Fix For: LATER > > I have found that, if you have a mapping with duplicated name properties,= such: > <hibernate-mapping xmlns=3D"urn:nhibernate-mapping-2.0" default-lazy=3D"t= rue"> > <class name=3D"Language, DataModel" table=3D"IRM_LANGUAGES" > dynamic-update=3D"true"> > <id name=3D"IdLanguage" column=3D"IdLanguage" unsaved-value=3D"0"> > <generator class=3D"native" /> > </id> > <many-to-one name=3D"Type" column=3D"IdLanguage" not-null=3D"true" /> > </class> > </hibernate-mapping> > Here, there is a typo because the column of the many-to-one tag is the sa= me as the column of the ID. We have found that, in this case, instead of wa= rning the user about the wrong mapping file, the exception is thrown when t= he query is sent to the database. --=20 This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.nhibernate.org/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: NHibernate J. <mik...@us...> - 2007-01-08 15:16:32
|
[ http://jira.nhibernate.org/browse/NH-823?page=3Dcomments#action_1473= 5 ] =20 Sergey Koshcheyev commented on NH-823: -------------------------------------- The check may be a worthy feature to work on sometime later. If two propert= ies are mapped to the same column then one of the columns should be marked = as insert=3D"false"/update=3D"false". > Duplicate column names should generate NH exception, not ADO.NET > ---------------------------------------------------------------- > > Key: NH-823 > URL: http://jira.nhibernate.org/browse/NH-823 > Project: NHibernate > Type: New Feature > Components: Core > Versions: 1.2.0.Beta2 > Reporter: Andr=C3=A9s G. Aragoneses > Priority: Minor > Fix For: LATER > > I have found that, if you have a mapping with duplicated name properties,= such: > <hibernate-mapping xmlns=3D"urn:nhibernate-mapping-2.0" default-lazy=3D"t= rue"> > <class name=3D"Language, DataModel" table=3D"IRM_LANGUAGES" > dynamic-update=3D"true"> > <id name=3D"IdLanguage" column=3D"IdLanguage" unsaved-value=3D"0"> > <generator class=3D"native" /> > </id> > <many-to-one name=3D"Type" column=3D"IdLanguage" not-null=3D"true" /> > </class> > </hibernate-mapping> > Here, there is a typo because the column of the many-to-one tag is the sa= me as the column of the ID. We have found that, in this case, instead of wa= rning the user about the wrong mapping file, the exception is thrown when t= he query is sent to the database. --=20 This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.nhibernate.org/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: NHibernate J. <nh...@gm...> - 2008-09-30 12:32:36
|
[ http://jira.nhibernate.org/browse/NH-823?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Fabio Maulo updated NH-823: --------------------------- Fix Version/s: (was: 2.1.0.Alpha1) > Duplicate column names should generate NH exception, not ADO.NET > ---------------------------------------------------------------- > > Key: NH-823 > URL: http://jira.nhibernate.org/browse/NH-823 > Project: NHibernate > Issue Type: New Feature > Components: Core > Affects Versions: 1.2.0.Beta2 > Reporter: Andrés G. Aragoneses > Priority: Minor > > I have found that, if you have a mapping with duplicated name properties, such: > <hibernate-mapping xmlns="urn:nhibernate-mapping-2.0" default-lazy="true"> > <class name="Language, DataModel" table="IRM_LANGUAGES" > dynamic-update="true"> > <id name="IdLanguage" column="IdLanguage" unsaved-value="0"> > <generator class="native" /> > </id> > <many-to-one name="Type" column="IdLanguage" not-null="true" /> > </class> > </hibernate-mapping> > Here, there is a typo because the column of the many-to-one tag is the same as the column of the ID. We have found that, in this case, instead of warning the user about the wrong mapping file, the exception is thrown when the query is sent to the database. -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.nhibernate.org/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: Fabio M. (JIRA) <nh...@gm...> - 2010-08-05 03:56:52
|
[ http://216.121.112.228/browse/NH-823?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Fabio Maulo closed NH-823. -------------------------- Resolution: Not an Issue As requested by reporter > Duplicate column names should generate NH exception, not ADO.NET > ---------------------------------------------------------------- > > Key: NH-823 > URL: http://216.121.112.228/browse/NH-823 > Project: NHibernate > Issue Type: New Feature > Components: Core > Affects Versions: 1.2.0.Beta2 > Reporter: Andrés G. Aragoneses > Priority: Minor > > I have found that, if you have a mapping with duplicated name properties, such: > <hibernate-mapping xmlns="urn:nhibernate-mapping-2.0" default-lazy="true"> > <class name="Language, DataModel" table="IRM_LANGUAGES" > dynamic-update="true"> > <id name="IdLanguage" column="IdLanguage" unsaved-value="0"> > <generator class="native" /> > </id> > <many-to-one name="Type" column="IdLanguage" not-null="true" /> > </class> > </hibernate-mapping> > Here, there is a typo because the column of the many-to-one tag is the same as the column of the ID. We have found that, in this case, instead of warning the user about the wrong mapping file, the exception is thrown when the query is sent to the database. -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://216.121.112.228/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |