A
Alessandro
Hello,
I'm writing some Date values into datetime fields inside a mySQL table using
hibernate (in the mapping file all that fields were declared as "date").
Everything works fine but I view also hh:mm:ss and I wouldn't view that in
the mySQL table.
The Date object has been formatted using SimpleDateFormat ("yyyy-MM-dd"),
time information shouldn't be valorized but then setting in the table I view
also time as 00:00:00.
Then do I need to set in some way tha date format:
1) in mySQL
2) somewhere in hibernate
3) transform datetime field into string and map it as "string", but this is
a poor workaround
4) else
Thanks all and best regards,
Ale
I'm writing some Date values into datetime fields inside a mySQL table using
hibernate (in the mapping file all that fields were declared as "date").
Everything works fine but I view also hh:mm:ss and I wouldn't view that in
the mySQL table.
The Date object has been formatted using SimpleDateFormat ("yyyy-MM-dd"),
time information shouldn't be valorized but then setting in the table I view
also time as 00:00:00.
Then do I need to set in some way tha date format:
1) in mySQL
2) somewhere in hibernate
3) transform datetime field into string and map it as "string", but this is
a poor workaround
4) else
Thanks all and best regards,
Ale