ashishpaliwal wrote:
>
> My guess.
> Since you are creating table and inserting outside of openjpa there might
> be
> a data type mismatch between the two id's definition in .java file and in
> database. For ex, in java file taking long as data type of id means bigint
> in mysql. So, I am "guessing" that there is difference of data types
> between
> the two definitions.
>
The DDL that created the table is below and the entity definitions were
created using the 'Create Enties from Table' tool in Eclipse. Any
suggestions as to what the .java definition for the id field should be?
CREATE TABLE ids2.Platform (
id INT NOT NULL AUTO_INCREMENT
, PlatformName VARCHAR(32)
, PRIMARY KEY (id)
) ENGINE = InnoDB;
ALTER TABLE ids2.Platform MODIFY COLUMN PlatformName VARCHAR(32)
COMMENT 'Platform Description';
Regards
--
View this message in context:
http://n2.nabble.com/NEWBIE-OpenJPA-Cannot-get-id-field-returned-tp3601995p3609198.html
Sent from the OpenJPA Users mailing list archive at Nabble.com.