Reputation: 959
When i right click on project then Maven then Add Dependencies. It is showing error. Artifact id cannot be empty. I had rebuild index. I don't know what to put in artifact id and group id. I want to add Hibernate libraries.
Upvotes: 0
Views: 389
Reputation: 6992
Put this in your pom.xml
in the section dependencies
:
<dependency>
<groupId>org.hibernate</groupId>
<artifactId>hibernate-core</artifactId>
<version>4.3.6.Final</version>
</dependency>
From the Maven documentation:
The minimum requirement for a POM are the following:
- project root
- modelVersion - should be set to 4.0.0
- groupId - the id of the project's group.
- artifactId - the id of the artifact (project)
- version - the version of the artifact under the specified group
Upvotes: 2