problem importing table

[email protected]
Newsgroups gmane.comp.gnu.enterprise.general
Message-ID <[email protected]>
Hello.

I'm using debian woody. I think this output(I've tried to obtain error
messages in english but failed) plus attached files will let you see
what's my problem (I think I do something wrong):

output >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
chafar@big:~/dev/gnue/buro/gsd$ ll /usr/bin/python
lrwxrwxrwx    1 root     root            9 mar 16 01:53 /usr/bin/python
-> python2.1
chafar@big:~/dev/gnue/buro/gsd$ gnue-schema --version

GNUe Schema Scripter
Versión 0.5.4

GNUe Common, versión 0.5.4

chafar@big:~/dev/gnue/buro/gsd$ ll ../../lib/base/gsd/org.gsd
-rw-r--r--    1 chafar   users        6612 may 25 20:36 \
../../lib/base/gsd/org.gsd
chafar@big:~/dev/gnue/buro/gsd$ gnue-schema --vendor postgresql -e \
ISO-8859-1 customer.gsd
Cargando fichero gsd 'customer.gsd' ...
No existe la tabla 'org_status'
No existe la tabla 'org_org'
Se encontraron errores al procesar fichero GSD
<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< output

Thanks in advance.
-- 
José Esteban
Granada - Spain
http://alcances.net

_______________________________________________
Gnue mailing list
[email protected]
http://mail.gnu.org/mailman/listinfo/gnue
customer.gsd (text/plain, 1 KB)
<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE schema PUBLIC "-//GNUe//GNURPC DTD Schema DTD 0.5.2.99//EN" " ">
<schema author="José Esteban" title="Buro customer schema" version="0.0.1">
  <tables>
    <import-table name="org_status" library="../../lib/base/gsd/org.gsd"/>
    <import-table name="org_org" library="../../lib/base/gsd/org.gsd"/>
<!--    <import-table name="loc_address" library="../../lib/base/gsd/location.gsd"/> -->
    <table name="buro_customer">
      <constraints>
	<constraint name="fk_bcust_org" type="foreignkey">
	  <constraintfield name="org"/>
	  <constraintref name="id" table="org_org"/>
	</constraint>
<!--
	<constraint name="fk_bcust_billaddr" type="foreignkey">
	  <constraintfield name="bill_address"/>
	  <constraintref name="id" table="loc_address"/>
	</constraint>
-->
      </constraints>
      <fields>
	<field name="id" type="key" auto="Y" defaultwith="serial" nullable="N"/>
	<field name="org" type="key" nullable="N"/>
	<field name="bill_address" type="key" nullable="N"/>
      </fields>
    </table>
  </tables>
</schema>
org.gsd (text/plain, 6.5 KB)
<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE schema PUBLIC "-//GNUe//GNURPC DTD Schema DTD 0.5.2.99//EN" " ">


<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - -
    todo:
	no nos funcionan los imports: al importar loc_address
	echa en falta loc_country y loc_region, y le da igual
	que importes estos antes
    - - - - - - - - - - - - - - - - - - - - - - - - - - - -->

<schema author="José Esteban" title="Organization related data schema" version="0.0.1">
  <tables>
    <!--    <import-table name="loc_address" library="location.gsd"/> -->

    <!-- status codes -->
    <table name="org_status">
      <fields>
	<field name="code" type="string" length="6" nullable="N"/>
	<field name="descr" type="string" length="20" nullable="N"/>
      </fields>
      <primarykey name="pk_org_status">
	<pkfield name="code"/>
      </primarykey>
    </table>

    <!-- communication device types -->
    <table name="org_comm_type">
      <fields>
	<field name="code" type="string" length="6" nullable="N"/>
	<field name="descr" type="string" length="20" nullable="N"/>
      </fields>
      <primarykey name="pk_comm_type">
	<pkfield name="code"/>
      </primarykey>
    </table>

    <!-- organization -->
    <table name="org_org">
      <constraints>
	<constraint name="uk_org_nick" type="unique">
	  <constraintfield name="nick"/>
	</constraint>
	<constraint name="fk_org_status" type="foreignkey">
	  <constraintfield name="status"/>
	  <constraintref name="code" table="org_status"/>
	</constraint>
      </constraints>
      <fields>
	<field name="id" type="key" auto="Y" defaultwith="serial" nullable="N"/>
	<field name="nick" type="string" length="25" nullable="N"/>
	<field name="name" type="string" length="60" nullable="N"/>
	<field name="created" type="datetime" defaultwith="timestamp" nullable="N"/>
	<field name="status" type="string" length="6" nullable="N"/>
	<field name="status_updated" type="datetime" defaultwith="timestamp" nullable="N"/>
      </fields>
      <primarykey name="pk_org">
	<pkfield name="id"/>
      </primarykey>
    </table>

    <!-- department -->
    <table name="org_dept">
      <constraints>
	<constraint name="fk_dept_org" type="foreignkey">
	  <constraintfield name="org"/>
	  <constraintref name="id" table="org_org"/>
	</constraint>
      </constraints>
      <fields>
	<field name="id" type="key" auto="Y" defaultwith="serial" nullable="N"/>
	<field name="org" type="key" nullable="N"/>
	<field name="role" type="string" length="15" nullable="N"/>
	<field name="name" type="string" length="30" nullable="N"/>
      </fields>
      <primarykey name="pk_org_dept">
	<pkfield name="id"/>
      </primarykey>
    </table>

    <!-- contacts
    linked to dept
    - - - - - - - - - - - - - - - - - - - -->
    <table name="org_contact">
      <constraints>
	<constraint name="fk_contact_dept" type="foreignkey">
	  <constraintfield name="dept"/>
	  <constraintref name="id" table="org_dept"/>
	</constraint>
      </constraints>
      <fields>
	<field name="id" type="key" auto="Y" defaultwith="serial" nullable="N"/>
	<field name="dept" type="key" nullable="N"/>
	<field name="role" type="string" length="20"/>
	<field name="name" type="string" length="40" nullable="N"/>
      </fields>
      <primarykey name="pk_org_contact">
	<pkfield name="id"/>
      </primarykey>
    </table>

    <!--
    communication device ids
    linked to dept and, optional, to contact
    - - - - - - - - - - - - - - - - - - - -->
    <table name="org_comm">
      <constraints>
	<constraint name="fk_comm_type" type="foreignkey">
	  <constraintfield name="type"/>
	  <constraintref name="code" table="org_comm_type"/>
	</constraint>
	<constraint name="fk_comm_dept" type="foreignkey">
	  <constraintfield name="dept"/>
	  <constraintref name="id" table="org_dept"/>
	</constraint>
	<constraint name="fk_comm_contact" type="foreignkey">
	  <constraintfield name="contact"/>
	  <constraintref name="id" table="org_contact"/>
	</constraint>
      </constraints>
      <fields>
	<field name="type" type="string" length="6" nullable="N"/>
	<field name="dept" type="key" nullable="N"/>
	<field name="data" type="string" length="20" nullable="N"/>
	<field name="contact" type="key"/>
      </fields>
      <primarykey name="id">
	<pkfield name="type"/>
	<pkfield name="data"/>
      </primarykey>
    </table>

    <!--
    adresses (bridge table: org/dept <-> address)
    linked to dept and address
    - - - - - - - - - - - - - - - - - - - -->

    <!--
    pendiente de que podamos importar address, o como sea que lo arreglemos
    
    <table name="org_address">
      <constraints>
	<constraint name="fk_address_org" type="foreignkey">
	  <constraintfield name="org"/>
	  <constraintref name="id" table="org_org"/>
	</constraint>
	<constraint name="fk_address_dept" type="foreignkey">
	  <constraintfield name="dept"/>
	  <constraintref name="id" table="org_dept"/>
	</constraint>
	<constraint name="fk_address_address" type="foreignkey">
	  <constraintfield name="address"/>
	  <constraintref name="id" table="loc_address"/>
	</constraint>
      </constraints>
      <fields>
	<field name="id" type="key" defaultwith="serial" nullable="N"/>
	<field name="org" type="key" nullable="N"/>
	<field name="dept" type="key" nullable="N"/>
	<field name="address" type="key" nullable="N"/>
      </fields>
    </table>

    	-->

  </tables>

  <data>
    <tabledata name="org_status_codes" tablename="org_status">
      <definition>
	<column field="code" type="string"/>
	<column field="descr" type="string"/>
      </definition>
      <rows>
	<row>
	  <value field="code">prop</value>
	  <value field="descr">Proposed</value>
	</row>
	<row>
	  <value field="code">active</value>
	  <value field="descr">Active</value>
	</row>
	<row>
	  <value field="code">block</value>
	  <value field="descr">Blocked</value>
	</row>
	<row>
	  <value field="code">restr</value>
	  <value field="descr">Restricted</value>
	</row>
      </rows>
    </tabledata>
    <tabledata name="org_comm_types" tablename="org_comm_type">
      <definition>
	<column field="code" type="string"/>
	<column field="descr" type="string"/>
      </definition>
      <rows>
	<row>
	  <value field="code">phone</value>
	  <value field="descr">Phone number</value>
	</row>
	<row>
	  <value field="code">fax</value>
	  <value field="descr">Fax number</value>
	</row>
	<row>
	  <value field="code">pob</value>
	  <value field="descr">Post office box</value>
	</row>
	<row>
	  <value field="code">mail</value>
	  <value field="descr">Mail Address</value>
	</row>
      </rows>
    </tabledata>
  </data>

</schema>
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.