Hibernate error java. Lang. illegalargumentexception: Timestamp format must be yyyy-mm-dd hh: mm: SS

Source: Internet
Author: User

Java. Lang. illegalargumentexception: Timestamp format must be yyyy-mm-dd hh: mm: SS

<11:51:43, 546> debug (hibernatetemplate. Java: 410) [http-8095-1] (Org. RD. Framework. hibernate. defaulthibernatetemplate)-Found thread-bound session for hibernatetemplate
Hibernate: Select viewdevice0 _. index_field as index1_226 _, viewdevice0 _. equipment_no as equipment2_226 _, viewdevice0 _. asset_category as asset3_226 _, viewdevice0 _. equipment_name as equipment4_226 _, viewdevice0 _. equipment_state as equipment5_226 _, viewdevice0 _. model
As model226 _, viewdevice0 _. register_person as register7_226 _, viewdevice0 _. register_date as register8_226 _, viewdevice0 _. use_dept as use9_226 _, viewdevice0 _. use_person as use10_226 _, viewdevice0 _. use_person_no as use11_226 _, viewdevice0 _. manage_dept as manage12_226 _,
Viewdevice0 _. manage_person as manage13_226 _, viewdevice0 _. fact_scrapped_date as fact14_226 _, viewdevice0 _. should_scraped_date as should15_226 _, viewdevice0 _. finance_recorded_date as finance16_226 _, viewdevice0 _. original_value as original17_226 _, viewdevice0 _. supplier
As supplier226 _, viewdevice0 _. make_business as make19_226 _, viewdevice0 _. serial_no as serial20_226 _, viewdevice0 _. warranty_start_date as warranty21_226 _, viewdevice0 _. warranty_end_date as warranty22_226 _, viewdevice0 _. use_date as use23_226 _ from view_device
Viewdevice0 _
<2012-08-09 11:51:44, 171> error (jdbcexceptionreporter. java: 78) [http-8095-1] (Org. hibernate. util. jdbcexceptionreporter)-An sqlexception was provoked by the following failure: Java. lang. illegalargumentexception: Timestamp format must be yyyy-mm-dd hh: mm: ss [. fffffffff]
<11:51:44, 812> debug (hibernatetemplate. Java: 435) [http-8095-1] (Org. RD. Framework. hibernate. defaulthibernatetemplate)-Not closing pre-bound hibernate session after hibernatetemplate

Cause:

Manage_person is of the varchar2 type. If my error is of the date type, this error is returned.
<Key-property name = "manage_person" type = "Java. util. Date">
<Column name = "manage_person"/>
</Key-property>
Change
<Key-property name = "manage_person" type = "Java. Lang. String">
<Column name = "manage_person"/>
</Key-property>

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.