Results 1 to 5 of 5
  1. #1
    Ed
    Ed is offline Senior Member
    Join Date
    Jun 2007
    Posts
    110
    Rep Power
    0

    Default org.hibernate.DuplicateMappingException: Duplicate class/entity mapping project

    I had this error
    org.hibernate.DuplicateMappingException: Duplicate class/entity mapping project.hibernate.User
    and I was searching on Internet about that. It appears because there is 2 persistent class with the same name. my question is:
    Is it count the extension ? because the classes that I used the same name are
    User.java y User.hbm.xml.
    Thanks

  2. #2
    Jack is offline Senior Member
    Join Date
    Jun 2007
    Posts
    130
    Rep Power
    0

    Default

    You surely have two User.hbm.xml in the classpath,
    check it

  3. #3
    bbq
    bbq is offline Senior Member
    Join Date
    Jun 2007
    Posts
    132
    Rep Power
    0

    Default

    User.java and User.hbm.xml are different
    check if User.hbm.xml has the same attributes that User.java has.
    Maybe you forgot some attribute

  4. #4
    xtps225 is offline Member
    Join Date
    Mar 2010
    Posts
    1
    Rep Power
    0

    Default

    我的属性一样也出现这个错误了!!!!!

  5. #5
    jorgwel is offline Member
    Join Date
    May 2011
    Posts
    1
    Rep Power
    0

    Default Re: This may help

    I had this problem. Check out the last two posts of this URL

    mapping file not found: .hbm.xml

    those were the solution for me.

Similar Threads

  1. random string are duplicate
    By googgoo in forum New To Java
    Replies: 3
    Last Post: 04-03-2008, 10:01 AM
  2. Help with image mapping
    By coco in forum AWT / Swing
    Replies: 1
    Last Post: 08-07-2007, 04:06 AM
  3. About servlet-mapping
    By Heather in forum Java Servlet
    Replies: 1
    Last Post: 07-14-2007, 06:00 PM
  4. Replies: 1
    Last Post: 07-06-2007, 06:27 AM
  5. Replies: 2
    Last Post: 06-30-2007, 03:01 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •