db-derby-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Hardie82 <thomas.harttha...@yahoo.de>
Subject implicite datacasting
Date Thu, 05 Nov 2009 09:34:17 GMT


I have a problem with an insert-statement. I have an application that used a
hsqldb. Now I want to switch to derby but got the problem that derby didn't
cast an integer to a char-column. I always get an exception by the following

INSERT INTO table1 (id, name, code) VALUES (1, 'somebody', 03184)

Column code is type varchar(20) and I read elcewhere that derby implicite
could parse this to varchar. Is this correct or should I cast it manually

INSERT INTO table1 (id, name, code) VALUES (1, 'somebody', '03184') ?

By the way with hsqldb the error didn't occur.

View this message in context: http://old.nabble.com/implicite-datacasting-tp26208648p26208648.html
Sent from the Apache Derby Users mailing list archive at Nabble.com.

View raw message