src-db/database/model/tables/M_INVENTORYLINE.xml
author Juan Pablo Aroztegi <juanpablo.aroztegi@openbravo.com>
Wed, 03 Sep 2008 17:55:37 +0000
changeset 1605 8a0fe0193bef
parent 1125 ce88e431b9b9
child 5551 7a30caea85b5
permissions -rw-r--r--
Merge r2.5x intro trunk
<?xml version="1.0"?>
  <database name="TABLE M_INVENTORYLINE">
    <table name="M_INVENTORYLINE" primaryKey="M_INVENTORYLINE_KEY">
      <column name="M_INVENTORYLINE_ID" primaryKey="true" required="true" type="VARCHAR" size="32" autoIncrement="false">
        <default/>
        <onCreateDefault/>
      </column>
      <column name="AD_CLIENT_ID" primaryKey="false" required="true" type="VARCHAR" size="32" autoIncrement="false">
        <default/>
        <onCreateDefault/>
      </column>
      <column name="AD_ORG_ID" primaryKey="false" required="true" type="VARCHAR" size="32" autoIncrement="false">
        <default/>
        <onCreateDefault/>
      </column>
      <column name="ISACTIVE" primaryKey="false" required="true" type="CHAR" size="1" autoIncrement="false">
        <default><![CDATA[Y]]></default>
        <onCreateDefault/>
      </column>
      <column name="CREATED" primaryKey="false" required="true" type="TIMESTAMP" size="7" autoIncrement="false">
        <default><![CDATA[SYSDATE]]></default>
        <onCreateDefault/>
      </column>
      <column name="CREATEDBY" primaryKey="false" required="true" type="VARCHAR" size="32" autoIncrement="false">
        <default/>
        <onCreateDefault/>
      </column>
      <column name="UPDATED" primaryKey="false" required="true" type="TIMESTAMP" size="7" autoIncrement="false">
        <default><![CDATA[SYSDATE]]></default>
        <onCreateDefault/>
      </column>
      <column name="UPDATEDBY" primaryKey="false" required="true" type="VARCHAR" size="32" autoIncrement="false">
        <default/>
        <onCreateDefault/>
      </column>
      <column name="M_INVENTORY_ID" primaryKey="false" required="true" type="VARCHAR" size="32" autoIncrement="false">
        <default/>
        <onCreateDefault/>
      </column>
      <column name="M_LOCATOR_ID" primaryKey="false" required="true" type="VARCHAR" size="32" autoIncrement="false">
        <default/>
        <onCreateDefault/>
      </column>
      <column name="M_PRODUCT_ID" primaryKey="false" required="true" type="VARCHAR" size="32" autoIncrement="false">
        <default/>
        <onCreateDefault/>
      </column>
      <column name="LINE" primaryKey="false" required="false" type="DECIMAL" size="10,0" autoIncrement="false">
        <default/>
        <onCreateDefault/>
      </column>
      <column name="QTYBOOK" primaryKey="false" required="true" type="DECIMAL" autoIncrement="false">
        <default><![CDATA[0]]></default>
        <onCreateDefault/>
      </column>
      <column name="QTYCOUNT" primaryKey="false" required="true" type="DECIMAL" autoIncrement="false">
        <default><![CDATA[0]]></default>
        <onCreateDefault/>
      </column>
      <column name="DESCRIPTION" primaryKey="false" required="false" type="NVARCHAR" size="255" autoIncrement="false">
        <default/>
        <onCreateDefault/>
      </column>
      <column name="M_ATTRIBUTESETINSTANCE_ID" primaryKey="false" required="false" type="VARCHAR" size="32" autoIncrement="false">
        <default/>
        <onCreateDefault/>
      </column>
      <column name="M_PRODUCT_UOM_ID" primaryKey="false" required="false" type="VARCHAR" size="32" autoIncrement="false">
        <default/>
        <onCreateDefault/>
      </column>
      <column name="QUANTITYORDER" primaryKey="false" required="false" type="DECIMAL" autoIncrement="false">
        <default/>
        <onCreateDefault/>
      </column>
      <column name="C_UOM_ID" primaryKey="false" required="false" type="VARCHAR" size="32" autoIncrement="false">
        <default/>
        <onCreateDefault/>
      </column>
      <column name="QUANTITYORDERBOOK" primaryKey="false" required="false" type="DECIMAL" autoIncrement="false">
        <default><![CDATA[0]]></default>
        <onCreateDefault/>
      </column>
      <foreign-key foreignTable="AD_CLIENT" name="ADCLIENT_MINVENTORYLINE">
        <reference local="AD_CLIENT_ID" foreign="AD_CLIENT_ID"/>
      </foreign-key>
      <foreign-key foreignTable="AD_ORG" name="ADORG_MINVENTORYLINE">
        <reference local="AD_ORG_ID" foreign="AD_ORG_ID"/>
      </foreign-key>
      <foreign-key foreignTable="C_UOM" name="COUMID_MINVENTORYLINE">
        <reference local="C_UOM_ID" foreign="C_UOM_ID"/>
      </foreign-key>
      <foreign-key foreignTable="M_ATTRIBUTESETINSTANCE" name="MATTRSETINST_MINVENTORYLINE">
        <reference local="M_ATTRIBUTESETINSTANCE_ID" foreign="M_ATTRIBUTESETINSTANCE_ID"/>
      </foreign-key>
      <foreign-key foreignTable="M_INVENTORY" name="MINVENTORY_MINVENTORYLINE">
        <reference local="M_INVENTORY_ID" foreign="M_INVENTORY_ID"/>
      </foreign-key>
      <foreign-key foreignTable="M_LOCATOR" name="MLOCATOR_MINVENTORYLINE">
        <reference local="M_LOCATOR_ID" foreign="M_LOCATOR_ID"/>
      </foreign-key>
      <foreign-key foreignTable="M_PRODUCT" name="MPRODUCT_MINVENTORYLINE">
        <reference local="M_PRODUCT_ID" foreign="M_PRODUCT_ID"/>
      </foreign-key>
      <foreign-key foreignTable="M_PRODUCT_UOM" name="MPRODUCTUOMID_MINVENTORYLINE">
        <reference local="M_PRODUCT_UOM_ID" foreign="M_PRODUCT_UOM_ID"/>
      </foreign-key>
      <index name="M_INVENTORYLINE_INVENTORY" unique="false">
        <index-column name="M_INVENTORY_ID"/>
      </index>
      <index name="M_INVENTORYLINE_PRODUCT" unique="false">
        <index-column name="M_PRODUCT_ID"/>
      </index>
      <check name="M_INVENTORYLINE"><![CDATA[((QUANTITYORDER IS NULL) AND (M_PRODUCT_UOM_ID IS NULL)) OR ((QUANTITYORDER IS NOT NULL) AND (M_PRODUCT_UOM_ID IS NOT NULL))]]></check>
      <check name="M_INVENTORYLINE_ISACTIVE_CHECK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
    </table>
  </database>