jsf myfaces calendar problem

hi, guys,

i have a problem with myfaces 1.1.1.

myfaces-all.jar used.

it is totally ok, can write the right date in DB, but the date readd from DB will be shown a day before the date of DB.a litte funny. for example, i choosed 2.1.2001 , correct write into db 1.1.2001, but if u read this from db, will be shown 1.1.2001

in jsp/jsf:

<t:inputCalendar id="employmentdate" monthYearRowClass="yearMonthHeader" weekRowClass="weekHeader" currentDayCellClass="currentDayCell" renderAsPopup="true" value="#{bean.attribute}" />

can u help me?

thanx

[591 byte] By [oftskya] at [2007-11-27 10:42:28]
# 1

This could be any number of things; locale issues, time zone issues. Also, the issue could be the locale, time zone difference from client to web server or from application to database.

RaymondDeCampoa at 2007-7-28 19:18:33 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 2

just use my desktop pc as server and client, tomcat ...

where can i check the issues?

oftskya at 2007-7-28 19:18:33 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 3

I'd start by looking in a debugger to see exactly what values are being set on the date objects. Also, try to verify what is actually in the database with a separate database client. Make sure the database client is displaying the timezone. Keep in mind that what timezone you display the date as can change the day of the month. I'd also take a look at the value of the date object after pulling it from the database.

RaymondDeCampoa at 2007-7-28 19:18:33 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 4

have seen , in mysql-database, if i write 10.07.07 into db, succeed in db ,

2007-07-10 00:00:00.0 in the data column of db. It could be the reason:2007-07-10 00:00:00.0 will be shown as 09.07.07, but how i can change this, in mysql or in jsp/jsf, let 2007-07-10 01:00:00.0 instead of 2007-07-10 00:00:00.0 be saved in db?

oftskya at 2007-7-28 19:18:33 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 5

thanx, i found the problem with myFaces 1.1.1 . Must write a converter to convert date-timezone like this: http://mail-archives.apache.org/mod_mbox/myfaces-users/200706.mbox/%3C002701c7b966$017efa10$8c01000a@cosys.de%3E

oftskya at 2007-7-28 19:18:33 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 6

the same problem occur in my project

i look the myfaces calendar source ,

if not do it like this ,i will be impossible to implement the calendar.

lysmarta at 2007-7-28 19:18:33 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...