For beginners, how do I configure sqlserver with hibernate? (Myeclipse) 2

Source: Internet
Author: User

The configuration of the database should be as follows:

<Property name = "hibernate. Connection. url"> JDBC: sqlserver: // 127.0.0.1: 1433; databasename = shopping; </property>

Shopping does not require quotation marks.

After the change, it was run that there was a syntax error near the user, and it took another half a day to know that the user was a keyword reserved by sqlserver, so I changed the table name to users,

In this way, I can confirm that I can connect to the database, but a new problem occurs. Modify the error again and change the ID attribute "ID" in the users table to "yes ", run the command to show that when identity_insert is set to off, explicit values cannot be inserted into the identifiers column of the table. This should be a problem in my database design. Unfortunately, I have not learned the database and the problem is to be solved.

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.