1. Advanced Mapping Question forum.hibernate.org |
2. mapping a Map containing a Set (Map |
3. Mapping Issue forum.hibernate.org |
4. Problem with hibernate mapping forum.hibernate.orgNewbie Joined: Mon Jan 22, 2007 9:47 am Posts: 1 Hi, I'm new to Hibernate and I am trying to map a simple database. I've used the Hibernate Synchronizer plugin for eclipse to generate the mapping files, but I keep getting this exception when I run the program: Code: Exception in thread "main" org.hibernate.MappingException: Repeated column in mapping for entity: com.opus.hibernate.Atividade ... |
5. Doubt about mapping forum.hibernate.org |
6. Unusual Mapping forum.hibernate.orgHello, I have the folowing problem. I have users entities. Every user refers a list of other users. I suppose this could be easly mapped with M-M, but the problem is that these relations between users, have to have an integer property wich represents the strenght of the relation. Could somebody help me with an ideas, how to map this? |
7. Question about hibernate mapping forum.hibernate.orgHi I have 2 tables Employee and Employee_Group. 1 employee can belong to only one employee_group and an employee_group may have multiple employees. Both these tables have employee_id as their primary key. Since I am new to hibernate, I wanted suggestions on how I can map these relations to get a set of employees on the employee_group class that belong to ... |
8. Many to one mapping forum.hibernate.orgHi, I have used Hibernate tools to reverse engineer my mapping files and POJO classes from an existing db which has gone well and all is working well. Hibernate tools has created many to one mappings for foreign keys in my mapping xml and POJO classes. The foreign key tables I have created contain only at most 4 entries which relate ... |
9. Mapping Issue forum.hibernate.orgHi friends .. i am facing some issues while creating the mapping file for the following tables.. Table 1 role contains the following columns roleid---- primary key roleName-- Description Table 2.. RightDetails contains the following columns roleid right ... primary key is a combination of roleid and right. That means the roleid can have multiple rights ... Can anyone help me ... |
10. Hibernate mapping problem forum.hibernate.org |
11. How to get Configuration or Mapping??? forum.hibernate.org |
12. Newbie | Mapping Question forum.hibernate.orgactually a many to many mapping might make more sense. A user can have multiple roles, but each of those roles would apply to many users. And I'm sure there will come a time when you need a list of all users with a specific role, rather than all roles for a specific user. |
13. Mapping information forum.hibernate.orgHello, I'm writting a form with a Text INPUT that will fill a VARCHAR in my BD. My question is how can i find in the BD or hirbernate mapping the size of the the VARCHAR to use this information to setup the maximum size of the Text INPUT in my form ? Thanks for your answer. |
14. mapping |
15. Can't get mapping to class forum.hibernate.orgNewbie Joined: Thu Feb 22, 2007 6:42 am Posts: 9 Hi, I am using Hibernate3 for the first time. Tried to map a simple MySQL of 2 tables. here is hibernate.cfg.xml file Code: |
17. 2 questions - avoiding blocking and mapping time zones forum.hibernate.orgi have two rather simple questions: 1) i am trying to lock a row prior to doing the update in order to avoid blocking other transactions updating the same row (i am using optimistic locking with a version column). I am doing the following to lock and update: session.lock(customer, LockMode.UPGRADE_NOWAIT); session.evict(customer); session.update(customer); as far as i understand the evict is needed ... |
18. Mapping Problem forum.hibernate.org |
19. Single class Category tree mapping forum.hibernate.orgWhen i pull children categories from class instance with .getChildren, i get correct list of children but with some null elements in the beginning. Number of these null elements depends on amount of records in table. But when i execute generated SQL in MySQL client, i get correct resultset. Without null recodrs. Have any ideas? Class(simplified): Code: public class Category extends ... |
20. Problem with many-to-many mapping. forum.hibernate.orgHi all, I am trying to insert in to multiple tables using many-to-many mappings.. I have a senario where i have to store primary keys of two tables(Table1 and Table2) in to another table(Relation), for which i am using many-to-one mapping.. in my table1.hbm.xml, i am specifying Code: |
21. Redundant 1:n mapping possible? forum.hibernate.orgHi, is there a way to have a one-to-many (e.g.) relationship more than once in a mapping? The example below illustrates that I'd like to have two distinct collections each referencing the same class "Child" but collection maleChildren contains only a subset (as collection femalChildren does) of all 1:n children. As I'd like to alter and persist both collections, a read-only ... |
22. Mapping a Set inside of a Map forum.hibernate.orgI couldn't find a good example of the kind of association mapping that I want to do, and my paltry understanding of Hibernate mapping is not sufficient for it. I want to store a Set of objects as the "value" in a Map, so that each entry in the Map is a Set. I know how to map a Map that ... |
23. Is dual mapping the only way? forum.hibernate.orgHello, I have an object A mapping to object B with many-to-one relationship. In the database schema table A has a B_ID column for this purpose. So normally if I want to get the ID of a B from A I'd do a.getB().getID(). The question is: for performance reason, can I get B_ID from A without first instantiating the B object? ... |
24. many to many mapping forum.hibernate.orgNewbie Joined: Thu Mar 22, 2007 10:39 am Posts: 14 hey! I'm kinda new to Hibernate, but I want to map some specific stuff: I have a many to many relationship, which relation table has some extra attributes. Because of that, I need an extra mapping file for the relationship table. Now, as I want to keep a Map |
25. Many-To-One enumeration class mapping? forum.hibernate.orgHi, I am using Hibernate 3.2 and ran into a problem with enum class mapping: Assume class Person has a field gender which is a type of GENDER enum class with only two instances GENDER.MALE and GENDER.FEMALE. It also has find method as GENDER.find(String str) where str can be "m" or "f". Further assume there is a gender table having id ... |
26. hibernate mapping problem :( forum.hibernate.org |
27. Can you solve this mapping dilemma? forum.hibernate.orgI'm currently trying to map a hashmap of name-value pairs in an entity. Seems easy enough, but I am working against a legacy schema which, of course, cannot be changed. The problem is the existing schema which in a distilled form is as follows: table: ENTITY_TABLE column: entity_id column: hashmap_id primary key: entity_id foreign key: hashmap_id to table HASHMAP_TABLE table: HASHMAP_TABLE ... |
28. Could not parse mapping document from invalid mapping forum.hibernate.organyone ecountered this error? couldnt find any solution in google. i have usccessfully done the sample tutorial for hibernate. my problem is when i integrate it with spring i cant understand why it cant map it successfully. it's even only a simple table with 5 columns that are all strings. ive already placed the necessary hiberante bean definitions in the spring-app.xml ... |
29. constrained one-to-one mapping problem forum.hibernate.org |
30. C3P0 connection pool initialized once for each mapping resou forum.hibernate.orgHi, I have configured hibernate to use C3P0. Whenever I stopped my application, the postgresql server that I am using will log a lot of "unexpected EOF on client connection ". And I did some investigation ...... I turned on my C3P0 logging. And I found that when I call configuration.buildSessionFactory(), I will have 1 + (number of mapping resources I've ... |
31. Could not compile the mapping document ... forum.hibernate.orgHibernate version: 1.2 Mapping documents: |
32. hibernate 3 mapping advice forum.hibernate.orghello, this may sound stupid but ... i have to create a domain entity model for vehicles, makes and models. a vehicle can be a car or a boat. also the make has a type because cars have different makes from boats (and i need to distinguish them when the user selects the make in a form). I was about to ... |
33. Mapping OK, execute failed forum.hibernate.orgHello Hibernate members! I am using MyEclipse to mapping a schema on OracleAS Portal - PORTAL, after mapping process I try to get all rows from a table inside but something wrong happended like following! I don't know why? 07/04/16 14:20:49 %%%% Error Creating SessionFactory %%%% org.hibernate.MappingException: Could not read mappings from resource: com/ncs/survey/portaldb/model/WwsecPerson.hbm.xml at org.hibernate.cfg.Configuration.addResource(Configuration.java:485) at org.hibernate.cfg.Configuration.parseMappingElement(Configuration.java:1465) at org.hibernate.cfg.Configuration.parseSessionFactory(Configuration.java:1433) at ... |
34. Unit Testing Hibernate Mappings? forum.hibernate.orgI would like to be create (or hopefully find) a nice framework for unit testing my mapping documents. Basically, I want to be able to say something like "assert that the 'name' property in the 'Person' class is mapped to the 'NAME' column in the 'PERSON' table." I would like to use the hibernate metadata to find out where the properties ... |
35. Hi With regards(Problem In Mapping) :-Urgent forum.hibernate.org |
36. one to one mapping issues forum.hibernate.orgHello Hibernate Users, Iam having the following issue with schema export tool . This is in regard to a one to one mapping. The hibernate version is 3.0 I have two Pojos's (user and user preferences), The relation ship to be defined between the pojo's is user <--- bi directional one to one----> user preferences. The mapping xml file for users ... |
37. Inhertance mapping woes forum.hibernate.orgHi guys I am using hibernate 3.2 GA as my persistance provider with mysql 5 as my database. I am trying to map an object model to the database model (or may be vice versa.) I have an Loan base object with its own Loan table. Then i have an LoanOptionARM object that extends Loan object and a couple of concrete ... |
38. Newbie - Switchable mapping? forum.hibernate.orgHello, I'm trying to evaluate whether we can use Hibernate for our project. I've been reading for several hours now and I'm stuck at some point. It looks like we cant use it but I'd like to be sure. In the project there will be business logic classes, lets say, ShowEntity and it will be functionally the same for every type ... |
39. Many-to-Many mapping forum.hibernate.orgFirst of all, you will definitely need another table to maintain such a relationship: The table, (maybe called SPEAKER_SUBSTITUTION) needs to have two columns, SPEAKER_ID and SUBSTITUTE_ID both of which reference the primary key of the SPEAKER table. Now, you can map this relationship like below: 1. In your Speaker.hbm.xml : |
40. Bad mapping?! How so? forum.hibernate.orgHibernate version: 3.x The mapping doc below works just fine. That is, it did before I added the sql-insert, -update, -delete statements. Now it won't even compile. I keep getting: Caused by: org.hibernate.MappingException: invalid mapping at org.hibernate.cfg.Configuration.addInputStream(Configuration.java:463) at org.hibernate.cfg.Configuration.addResource(Configuration.java:520) ... 143 more Caused by: org.xml.sax.SAXParseException: The content of element type "class" must match "(meta*,subselect?,cache?,synchronize*,comment?,tuplizer*,(id|composite-id), discriminator?,natural-id?,(version|timestamp)?,(property|many-to-one|one-to-one| component|dynamic-component|properties|any|map|set|list|bag|idbag|array|primitive-array)*, ((join*,subclass*)|joined-subclass*|union-subclass*),loader?,sql-insert?,sql-update?,sql-delete?, filter*,resultset*,(query|sql-query)*)". at org.apache.xerces.util.ErrorHandlerWrapper.createSAXParseException(Unknown Source) ... |
41. Hibernate Mapping problem forum.hibernate.orgI am new to Hibernate. I try to do a one to many mapping for two table. I setup the class file, and the hbm mapping xml file for two class. However, when I run the program. It can load the data from parent table. but it just return nothing for child. my table is like following create table INFO( INFO_ID ... |
42. tree mapping forum.hibernate.orgI am not quite sure how to map a recursive tree class that looks like this. class TreeItem { int id; // identifier String name; TreeItem parent[]; ... } The database schema I want to generate should lhave 2 tables. One table that holds each TreeItem and another called TreeParent which contains the ids of a TreeItem's parent(s): create Table TreeItem ... |
43. mapping One-to-One fileds forum.hibernate.orgI am new to hibernate and to ORM in general. How do I map a filed in a class to another field in different class ? If I have a property Employee.title that Should have a the value of Position.name and not the class position, how do I get around this ? in other words, there's a table called Employee. title ... |
44. Hibernate Mapping forum.hibernate.org |
45. char mapping problem forum.hibernate.orgHi, Im having trouble with char mapping to String. I have a table called "mrconso" in my MySQL database and the following entity: @Entity @Table(name = "MRCONSO") @NamedQuery(name = "mrconsoStr", query = "select i from Mrconso i where str like :terms") public class Mrconso implements Serializable { private Blob str; private String cui; @Id @GeneratedValue public Blob getStr() { return str; ... |
46. Hibernate 3.0.5 -> 3.2.3 migration problems (mappings etc forum.hibernate.org |
47. Purpose of many-to-many mapping - how to get the HashSet forum.hibernate.org |
48. Bi-directional Mapping forum.hibernate.orgHello, I am trying to maintain the following model described below. I am going to describe it in high level terms as I would like an example of how to map it. I have looked in the hibernate forum and been using the Hibernate In Action book, however I'm still confused. Model: I have a User object which holds a collection ... |
49. Mapping problem where 2 different classes have the same map forum.hibernate.orgHello, i am trying to make my project for studies using hibernate but i've come across a problem i cant solve nor can found any help in tutorial. Well i have classes and mappings more less like this class X{ map |
50. mapping a hashtable forum.hibernate.orgHello! I have a problem mapping a hashtable to the database (MySQL). The problem is when I try to get an object from a table in which there exist any property hashtable. firstly, in my mapping archive I put this: |
51. Mapping one-to-many forum.hibernate.orgMapping documents: |
52. Question about Hibernate Mapping many-to-one forum.hibernate.orgHi all, I was trying understand Hibernate in my small application I have this db structure(mysql): create table instructors ( instructor_id int(4) primary key, first_nm varchar(50), last_nm varchar(50) ); create table courses ( course_id int primary key, instructor_id int , course_cd varchar(50), course_nm varchar(50) ); alter table courses add foreign key (instructor_id) references instructors(instructor_id) and my Hibernate maps: Code: ... |
53. Best Practice for mapping references to TPC Inherritance forum.hibernate.orgI have this problem quite often where my objects have polymorphic relationships to legacy tables that don't implement SingleTableInherritance mappings, or Joined Subclass Mappings. So say for example I have something like: @Entity public class Deployment { private Target target; } @Entity public class Webserver implements Target { } @Entity public class Desktop implements Target { } My two legacy tables ... |
54. Newby Mapping Question forum.hibernate.org |
55. Problem with mapping forum.hibernate.org |
56. OR Mapping Question forum.hibernate.orgHi, I'm kind of new to Hibernate and we've decided to migrate our current application by using Hibernate as the persistence layer. This will involve the changes of both entity classes and database schema. In order to make the transition smooth, I'd like to do it in two steps: 1. Define entity classes using annotions. 2. Change the underlying database schema ... |
57. 1-many mapping forum.hibernate.orgHi, I have a master table and details table. they have 1-many relationship from master to details. Details, you can think of as history or different old versions of a record in the master. Now if we want to have only one class in the domain model, is there any way to map this 1-many relation into one domain class in ... |
58. Problem with mappings forum.hibernate.orgMapping documents: [/<] |
59. Problem with one-to-many mapping forum.hibernate.orgHi, I am trying the one-to-many relationship in hibernate and am getting the following error , Quote: [6/28/07 12:36:50:704 IST] 13cc2959 AbstractFlush E org.hibernate.event.def.AbstractFlushingEventListener Could not synchronize database state with session [6/28/07 12:36:50:766 IST] 13cc2959 AbstractFlush E org.hibernate.event.def.AbstractFlushingEventListener TRAS0014I: The following exception was logged org.hibernate.TransientObjectException: object references an unsaved transient instance - save the transient instance before flushing: com.coalesce.vo.COLTask at org.hibernate.engine.ForeignKeys.getEntityIdentifierIfNotUnsaved(ForeignKeys.java:219) ... |
60. How to map a negative Time forum.hibernate.org |
61. Could not parse mapping document from resource forum.hibernate.orgNewbie Joined: Mon Jul 23, 2007 9:36 am Posts: 2 Need help with Hibernate? Read this first: http://www.hibernate.org/ForumMailingli ... AskForHelp Hibernate version:3.0 Mapping documents:profile.hbm.xml Code between sessionFactory.openSession() and session.close(): Code: Session session = null; try{ ... |
62. Maps and UserTypes forum.hibernate.orgCan the type of a map-key be a UserType? I have a pretty basic map whose key type is a usertype. And when I try to access my parameters collection, even though the map's entryset is loading fine it's keyset is loading as null. My map looks like this..... |
63. Mapping of sets, and calling a parameterised stored proc forum.hibernate.orgThis should be easy to do in Hibernate, but I can't figure it out. I have a SQL table called MEMBER that has, among other fields, these two: MEMBER_ID (a long integer, primary key) MEMBER_NAME (a string) I also have a MEMBER_ATTRIBUTE table with the following fields: ATTRIBUTE_NAME (a string) MEMBER_ID (long integer, refers to member_id in my MEMBER table) Two ... |
64. Specific mapping forum.hibernate.orgI need a very specific mapping. Let say I have a class having ListArray of values. How can tell Hibernate engine how to map these values into a database in real time. No hbm files should be precreated and no annotations eather. Is there any mechanism, that I could say: PersistentObject po = manager.loadPersistentObject("Person", 23); po would need to be mapped ... |
65. Question to Hibernate documentation for mappings forum.hibernate.orgHello, I have a question to the Hibernate documentation chapter 1.3.2: A unidirectional Set-based association ( http://www.hibernate.org/hib_docs/v3/re ... sociations ). The original table structure of the example is: Code: _____________ __________________ | | ... |
66. Could not parse mapping document from resource... forum.hibernate.orgi'm learning JSF for the moment and thought it was a good moment to use hibernate with it for my access layer... all said and done, i downloaded hibernate, read the tutorial and tried something on my own but unfortunattly i get an error: org.hibernate.InvalidMappingException: Could not parse mapping document from resource DAL/Users.hbn.xml This is my Users.hbn.xml: Code: |
67. Mapping problem: company => person => function forum.hibernate.org |
68. Mapping Question forum.hibernate.orgMapping question from newbee, I have the following interest rate table (note: a tier is associated with a min balance); COMPANY TIER EFFECTIVE_DATE THROUGH_DATE INTEREST_RATE YIELD 902 1 7/9/2007 7/15/2007 0.00 0.00 902 2 7/9/2007 7/15/2007 1.82 0.00 902 3 7/9/2007 7/15/2007 2.32 0.00 902 1 7/16/2007 7/22/2007 0.00 0.00 902 2 7/16/2007 7/22/2007 1.82 0.00 902 3 7/16/2007 7/22/2007 2.32 ... |
69. How to map Set |
70. mapping for function forum.hibernate.org |
71. Hibernate mapping question forum.hibernate.orgHibernate version:Hibernate 3.2.4.sp1 //User.java public class User { long userId; String fName; Address address; //all getter and setters and constructor } //Address.java public class Address { long addressId; long userId; String street; //all getter and setters and constructor } User object has just a ref. to Address object. I need little help as to what kind of mapping I need to ... |
72. Mapping several "unrelated" classes to single tabl forum.hibernate.orgI'm trying to simulate 'views' of a single table (row) with several different objects, but am unclear on the possibility and implications of doing so. Here is an example: Code: @Entity @Table(name="device") public class DeviceBase { @Id @Column(name="device_id") private int deviceId; @Column(name="ip_address") ... |
73. Can't do a very simple mapping forum.hibernate.orgHello, here's my case: According to my domain model: A School has many Students. and the relation is unidirectional However when I use Set, adding a new student to a school causes entire students to be loaded. If there are 1 million students, that's a big problem. In this sense , Sets are useless to me. Using a bag is also ... |
74. Mapping many-to-one question forum.hibernate.org |
75. One-To_many mapping question forum.hibernate.orgI am trying to do a simple one-to-many with JPA. Entity 1 is publisher and Entity 2 is book. One book has only one publisher whereas one publisher has multiple books. Excerpts from the code: Code: @Entity public class Book implements Serializable{ @Id private int book_id; ... ... |
76. Mapping problem forum.hibernate.orgAuthor Message grohit Post subject: Mapping problem Posted: Sun Sep 02, 2007 2:24 pm Newbie Joined: Sun Sep 02, 2007 2:02 pm Posts: 2 Hi, I am stuck with a mapping problem. I have an accounts table(PycisVO.hbm.xml) and an exception table(Rule.hbm.xml), the relation between the two is many-to-many (RuleException.hbm.xml) PycisVO.hbm.xml Code: |
83. A one-to-one mapping problem forum.hibernate.orgDear All, I am trying to learn one-to-one mapping in Hibernate. Could anyone please help me out? This was what I had tried: Transaction.hbm.xml and MqTransaction.hbm.xml: Code: |
84. one-to-one mapping problem forum.hibernate.orgThanks Satish. But the code is throwing TypeMisMatchException. I am using:- Hibernate 3.2 Struts 1.2.9 Sun Java System Application Server 9 jdk 1.6 JavaDB 10.2.2 as backend the code is:- session=factory.openSession(); String queryString = "from hibernate.pojo.Users"; Query query = session.createQuery ( queryString ); List |
85. HOW TO map an OLAP cube? forum.hibernate.orgHello, I have posted this message on french Forum, but for now no answers. Maybe you can, or someone wants to know too! I have to access to a data located on an OLAP cube(MSAS) and display it on HTML page with other data from Sql-server 2005 DataBase (no reporting). My application runs on WAS 6.0. Can I map this OLAP ... |
86. Interesting Mapping problem. forum.hibernate.orghey guys, i have an interesting problem regarding the way hibernate maps property names to get and set methods. I may have missed the specification of the naming somewhere in the docs however bare with me. I have a property named: c1000$ I think it maps to a get method named : C1000$ () or is it this? : c1000$() //since ... |
87. Hibernate - Stored Procedure and Mapping forum.hibernate.orgHi There! I'm facing problems with my web-app using hibernate. I have a stored procedure in my database that returns me a table. the fields are coditabe, inclaces, alteaces, consaces, exclaces the question is... how do I do to map this one? I have read that it's on this way: Code: |
88. hibernate mapping got DuplicateMappingException forum.hibernate.orgHi, I'm new to Hibernate and I got trouble with mapping using Hibernate & Spring. The exception thrown was org.hibernate.DuplicateMappingException. I'm using inheritance mapping using joined-subclass on separate mapping file. It seems like I have to define the superclass mapping before subclass to make it work. If i put the subclass mapping first, it always throws the DuplicateMappingException. Please see the ... |
89. Stored procedure mapping problem forum.hibernate.orgMy problem is that i have a result set returned from an oracle stored procedure , and i do not have an id field ( in that particular resultset ) . How can i generate an id field localy ? Because it seems that the |
90. How to map tow ForeignKey to one PrimaryKey? forum.hibernate.orgI have this two tables: table1 ------------ id <--- Primary key id1 table2 ------------- id3 <------- Primary key id id1 And i want map {id,id1} from table2 to {id, id1} from table1 (two -> two). Please hekp me... i read only cant if table1 have two primarykey but i dont know if its really... (sorry for my english). |
91. Hibernate doubt in mapping forum.hibernate.orgHello, I have the map xml below. I want that my object Basket, is related to serviceBasket not with the field "id" of basket, but with the filed "bookid" of basket. How can I do? this is the file xml : |
92. Mapping twice forum.hibernate.orgHi, Anyone knows if it's possible to map a class instances as lists for other 2 class instances? For instance, I have 3 tables - one with jobs(projects), one with workers and one with hours. On each job I may have workers working a number of hours at different pay rates at different moment in times. I'd like to be able ... |
93. unit testing when mapping has 'where' clause with sysdate forum.hibernate.orgI am using Hibernate 2 and have the following property mapping which has a WHERE clause that filters on 'sysdate' to return the first period after todays date. |
94. how to write mapping forum.hibernate.org |
95. mapping question forum.hibernate.orgHi. Im trying to map Areas and Persons. Each Area has 4 specific persons. 1. A Warden 2. A Chief Warden 3. A Comms Officer 4. A Deputy Chief Warden I have modelled this as an Area object containing a 'warden' Person object, a 'chiefWarden' Person object, a 'deputyChiefWarden' person object etc. The Person object has firstName, lastName etc. I will ... |
96. Crazy Mapping Problem forum.hibernate.orgNewbie Joined: Wed Nov 07, 2007 2:46 pm Posts: 6 I want to persist this: The class Elemento persist fine with this mapping: Code: |
97. Strange Problem : could not read mapping from resource forum.hibernate.orgHello, I use Tomcat 5 and Hibernate 3.0. I have an app that make a search on db by "criteria" hibernate. All works fine. But sometimes, after some hours, I have this error: "Configuration problem: Could not read mappings from resource: basket.hbm.xml" and the search doesn't works ! If I restart Tomcat, all works fine. How can it be possible??! Thanks ... |
98. Result set mapping for NamedNativeQuery is throwing exceptio forum.hibernate.orgHi All, I think this is some configuration problem but I am not able to get resultSetMapping working with NamedNativeQuery. Hibernate is not using the result set mapping provided by me. Instead it is using the default mapping and throwing exception. Please see below all the config/code and exception details. Regards, Anshaj Hibernate version: hibernate-3.2 Mapping documents: @Entity @Table(name = "city") ... |
99. How to make one-to-one mapping? forum.hibernate.org |
100. Strange problem: Could not read mappings from resource: xxx. forum.hibernate.orgHello, yesterday I have got this problem: I have my java app that use Hibernate (3.0) for make search on DB (MySQl 5.0). If I sent a search method (with hibernate method "session.createCriteria"), sometimes it worked good, and sometime it gives me this error: " org.hibernate.MappingException: Could not read mappings from resource: basket.hbm.xml at org.hibernate.cfg.Configuration.addResource(Configuration.java:485) at org.hibernate.cfg.Configuration.parseMappingElement(Configuration.java:1465) at org.hibernate.cfg.Configuration.parseSessionFactory(Configuration.java:1433) at org.hibernate.cfg.Configuration.doConfigure(Configuration.java:1414) ... |