Hibernate Insert Database error

Source: Internet
Author: User

Hibernate:insert to Tme_merchandisecinfo (ID, Merchandisecname, SortID, State, Merchandisecid) VALUES (?,?,? , ?, ?)
[11-11 10:53:41] [Http-bio-8080-exec-1] [ERROR] [org.hibernate.engine.jdbc.spi.sqlexceptionhelper-146]-cannot be a table ' Tme_merchandisecinfo ' when IDENTITY_INSERT is set to OFF Inserts an explicit value in the identity column.
[11-11 10:53:41] [Http-bio-8080-exec-1] [ERROR] [Org.hibernate.engine.jdbc.batch.internal.abstractbatchimpl-175]-hhh000352:unable to release batch statement ...
[11-11 10:53:41] [Http-bio-8080-exec-1] [ERROR] [Org.hibernate.engine.jdbc.batch.internal.abstractbatchimpl-176]-hhh000246:sqlexception escaped proxy
Java.sql.SQLException:org.apache.commons.dbcp.DelegatingPreparedStatement with Address: " Sqlserverpreparedstatement:32 "is closed.

Hibernate framework defaults to all field interpolation in the database, including self-growth, so the above error is reported, if you do not want Hibernate to give you a field interpolation in addition to this sentence (@Column (name = "Field name"insertable = False, updatable = False,deletetable=false) Three means that a field is not assigned a value when inserting (updating) (deleting) data

@Column (name = "ID")

Hibernate Insert Database error

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.