Fixes bug 10246 Missing unique constraint on c_elemenvalue.value
authorVinoth Babu <vinoth.babu@openbravo.com>
Thu, 13 Aug 2009 22:22:50 +0530
changeset 4491 0711d379842e
parent 4490 b7c077bd1a18
child 4492 b10bedd14f64
Fixes bug 10246 Missing unique constraint on c_elemenvalue.value
src-db/database/model/tables/C_ELEMENTVALUE.xml
--- a/src-db/database/model/tables/C_ELEMENTVALUE.xml	Thu Aug 13 16:11:01 2009 +0200
+++ b/src-db/database/model/tables/C_ELEMENTVALUE.xml	Thu Aug 13 22:22:50 2009 +0530
@@ -135,6 +135,10 @@
       <index name="C_ELEMENTVALUE_NAME" unique="false">
         <index-column name="NAME"/>
       </index>
+      <unique name="C_ELEMENTVALUE_VALUE">
+        <unique-column name="C_ELEMENT_ID"/>
+        <unique-column name="VALUE"/>
+      </unique>
       <check name="C_ELEMENTVALUE_ISACTIVE_CHECK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
       <check name="CELEMVAL_ISBANKACCOUNT_CHECK"><![CDATA[ISBANKACCOUNT IN ('Y', 'N')]]></check>
       <check name="CELEMVAL_ISDOCCONTROL_CHECK"><![CDATA[ISDOCCONTROLLED IN ('Y', 'N')]]></check>