Hi,
I have an admin page that is inserting a record into a database. The table
was created via:
CREATE TABLE DRYGOODS
(
OI INT DEFAULT AUTOINCREMENT INITIAL 100 INCREMENT 1 NOT NULL ,
ITEMID VARCHAR(100) NOT NULL ,
ITEMNAME VARCHAR(200) NOT NULL ,
ITEMDESC VARCHAR(200),
QTY INT,
PRICE DOUBLE PRECISION
)
in by dbforms.xml I have defined the table up via:
<table name="DRYGOODS">
<field name="OI" fieldType="int" size="10" isKey="true"
autoInc="true"/>
<field name="ITEMID" fieldType="varchar" size="100" sortable="true"/>
<field name="ITEMNAME" fieldType="varchar" size="200" sortable="true"/>
<field name="ITEMDESC" fieldType="varchar" size="200"/>
<field name="QTY" fieldType="int" size="10"/>
<field name="PRICE" fieldType="double precision" size="52"/>
</table>
When I try to insert a record into this table I get this error on my page:
Error: Field type seems to be incorrect - java.lang.NumberFormatException:
null
When I look in the catalina.log file I see this:
java.sql.SQLException: Field type seems to be incorrect -
java.lang.NumberFormatException: null
at org.dbforms.util.SqlUtil.fillPreparedStatement(SqlUtil.java:132)
at org.dbforms.FieldValue.fillPreparedStatement(FieldValue.java:494)
at org.dbforms.FieldValue.populateWhereEqualsClause(FieldValue.java:338)
at org.dbforms.Table.getDoSelectResultSet(Table.java:458)
at org.dbforms.Table.doConstrainedSelect(Table.java:504)
at org.dbforms.event.InsertEvent.processEvent(InsertEvent.java:350)
Even though I get the error the record actually goes in. Updates on the
record work fine.
Anyone have any ideas. This error is occuring on a production web site so I
cannot step through the code etc.
Thanks
Alex
_______________________________________________________________
Don't miss the 2002 Sprint PCS Application Developer's Conference
August 25-28 in Las Vegas -- http://devcon.sprintpcs.com/adp/index.cfm
_______________________________________________
DbForms Mailing List
http://www.wap-force.net/dbforms