Regular |
|
Joined: Sat May 15, 2004 4:27 am Posts: 79
|
Hi all,
i am using MySQL database with hibernate. Does someone can tell
me how to declare a timestamp column in the hibernate mapping
file. At current i did that :
<property name="dateLogin" type="java.sql.Timestamp" column="date_login" not-null="true" />.
I create a java file too : Foo.java
public class ...
private Timestamp dateLogin;
....
setter/getter
This is the informations i want to insert into my table :
kurk
sdsds
127.0.0.1
127.0.0.1
2004-05-26 12:36:40
i am using session.save() method. I obtain that exceptioin :
Hibernate Exception: could not insert: [com.test.Foo]
---
Best regards
seb
|
|