[tinysql] This table does not support INTEGER

Thomas Siedschlag thomas.siedschlag@x-cellent.com
Fri, 30 Apr 2004 11:23:17 +0200


Hi Fabian,

 >
 > I=92m receiving =84ORG.as220.tinySQL.tinySQLException: This table does=
 not
 > support INTEGER=94
 >
 > while running the example TestDbf.
 >
 >
 >
 > CREATE TABLE cars (name CHAR(25), id INT)
 >
 > This table does not support INTEGER
 >
 > Please help its URGENT !!!
 >
 >

please check your table type.

In dbfHeader.java only following table types are allowed for integers.

   /**
    * All db4-tables and VisualFoxPro support integer values.
    */
   public boolean supportsInteger()
   {
     if (type =3D=3D TYPE_VISUAL_FOXPRO ||
         type =3D=3D TYPE_DB4_MEMO ||
         type =3D=3D TYPE_DB4_SQLSYSTEM_NOMEMO ||
         type =3D=3D TYPE_DB4_SQLTABLE_MEMO ||
         type =3D=3D TYPE_DB4_SQLTABLE_NOMEMO)
     {
       return true;
     }
     return false;
   }

Perhaps you can switch your column definition from INT to NUMERIC.

Regards
--=20
Thomas Siedschlag
x-cellent technologies GmbH
Rosenkavalierplatz 5
81925 Muenchen
Germany
e-mail thomas.siedschlag@x-cellent.com
http://www.x-cellent.com