Hi, if I set some properties in my class to not be nullable, and then generate the NHibernate mapping, the generated properties in the .hbm.xml file doesn't have not-null="true" set. I can get the not-null="true" in the mappings if I explicitly set the Not Null option in the Column Editor.
Is there a setting somewhere to get the generated mapping to use the properties' Nullable flag instead of having to edit all my columns in the Column Editor? Thanks!
Nullable generated NHibernate mapping properties
Re: Nullable generated NHibernate mapping properties
Here is an extract from Entity Developer documentation concerning the Not Null column property in Column Editor:
Nullable=false
Not Null=unspecified
=> there is no not-null="true" in the *.hbm.xml file.
We will post here when the issue is fixed.
We have reproduced the following behaviour:if selected, specifies that the column should be non-nullable. If the value of the Not Null check box is not specified explicitly, i.e. is not checked or unchecked, its value will be calculated depending on the Nullable property value of the corresponding property.
Nullable=false
Not Null=unspecified
=> there is no not-null="true" in the *.hbm.xml file.
We will post here when the issue is fixed.
Re: Nullable generated NHibernate mapping properties
The bug with generating the Not Null column attribute in the xml-mapping file basing on the Nullable property is fixed. We will post here when the corresponding build of Entity Developer is available for download.
Re: Nullable generated NHibernate mapping properties
Great! Thank you for looking into it.
Re: Nullable generated NHibernate mapping properties
New build of Entity Developer 4.7.285 is available for download!
It can be downloaded from http://www.devart.com/entitydeveloper/download.html (trial version) or from Registered Users' Area (for users with active subscription only).
For more information, please refer to http://forums.devart.com/viewtopic.php?f=32&t=25093.
It can be downloaded from http://www.devart.com/entitydeveloper/download.html (trial version) or from Registered Users' Area (for users with active subscription only).
For more information, please refer to http://forums.devart.com/viewtopic.php?f=32&t=25093.