I'm saving an entity in hibernate with a creation date
@Id
@Column(name = "dtcreation")
@Type(type="timestamp")
private Date creation;
and I put a new Date on this field:
entity.setCreation(new Date());
entityDao.persist(entity);
but when it is saved on the db the time don't contains the milliseconds, but put it a 0
if I try to update with a query the value of the milliseconds it works...someone can help me?
после метода сохранения у меня есть запись с 06.01.2011 15:00:00.0, но если я сделал ОБНОВЛЕНИЕ, я могу изменить миллисекунды, поэтому БД поддерживает это .. база данных informix