problem « Table « JPA Q&A





1. problem with hsqldb database specificaly table dropping, using hsqldb/hibernate with my maven project    stackoverflow.com

I am very new to this. And I am trying to configure a net-beans Maven project with hsqldb and hibernate. I have set up the database and I am able to ...

2. VWP/Hibernate - data table create record problem    forums.netbeans.org

Neil B. Cohen Posted via mailing list. Posted: Mon Aug 17, 2009 5:17 pm Post subject: VWP/Hibernate - data table create record problem Hi, I'm running NB6.5 building ...

3. VWP/Hibernate - data table create record problem - solved...    forums.netbeans.org

Sorry to bother everyone with this - turns out that 'range' is a MySQL keyword, so putting it in as a column name caused the system to blow up... Fixed it ...

4. Problem matching tables using hibernate    forums.netbeans.org

Hi all, I'm getting familiar with java and netbeans. I used to use python and SQLAlchemy (same technology as hibernate). I have problems matching tables. I've got to map netbeans with my oracle remote database using jdbc:obdbc driver (windows). I couldn't get Oracle OCI or Oracle Thin working. So we try to run hibernate.reveng.xml to match tables, I don't see any ...

5. problem with Hibernate and table named "users"    coderanch.com

Hi All, I have a somewhat annoying problem. In my database (MSSQL) I have a "users" table. The convention for hibernate seems to be to name the class as the singular so I have "data.User" as a classname. When I issue a query: String query = "select user from user " + "in class data.User " + "where username=:name"; and call: ...

6. Hibernate and a Table called [group] - problem    coderanch.com

Hi all I need to model a table called group which, being an SQL keyword is giving me some problems. My Group.hbm.xml file is defined as: When I try and query the database, the following sql is produced this_.groupCode ...

7. Hibernate Table dividing Problem    coderanch.com

Hi, I have an issue raised due to the splitting of a table into two Present Scenario:-I have a table mapped to an Hibernate hbm file and a class New Requrement:-Due to some reasons the database team divided the table into two new tables with some common columns but with same primary key.So ideal case ie we need to write two ...

8. JPA: Problem with InheritanceType.SINGLE_TABLE    coderanch.com

Hi all, I have 2 class, one that inherits from the other and I'm using InheritanceType.SINGLE_TABLE with a column that identifies if the entry belongs to the base class or to the derived class. This is the base class: @Entity @Table(name = "elutenti_utenti") @NamedQueries({ @NamedQuery(name = "Utente.findAll", query = "SELECT u FROM Utente u"), @NamedQuery(name = "Utente.findById", query = "SELECT u ...

9. redundant table problem in hibernate    forum.hibernate.org

Hi, I might be lacking in my knowledge as following might be expected behavior. I want to persist an object of class Position which is has a member of class Balance as follows: Class Position{ private balance = new Balance(); } where Class Balance{ private Map money = new HashMap(); } Now my mapping file for above is as follows: Code: ...





10. Problem with table creation with hbm2dll    forum.hibernate.org

Newbie Joined: Tue Sep 14, 2010 3:51 am Posts: 2 Hi, I've recently started a small project that will use Hibernate. I use Hibernate core version 3.3.1.GA. For testing, we will use Hsqldb in file mode. I have two persistent classes, two mapping files and a hibernate.cfg.xml file. However, even though I've configured Hibernate to automatically create the tables, this fails ...

11. Problem displaying set value in table    forum.hibernate.org

Hello members, Have another problem here.. All things work, except displaying the values from the set of an object. In stead of displaying values, it show the object ( class name, with a number ) Anyone here know how i can deal with that, so that it shows a value in stead of that? thanks in advance. [ dont know if ...

12. problem for export table    forum.hibernate.org

Hello, hi use hibernate and interbase... When i export my tables with schemaexport the program export my table but don't create the alter table... example of the error : alter table PPage add constraint FK48D2EFF6BFA6263 foreign key (format_id) references Format Unsuccessful: [interclient][interbase] unsuccessful metadata update object FORMAT is in use Can you help me ...

13. problem with table-per-class-hierarchy strategy    forum.hibernate.org

Hi all, any advice would be appreciated!! I have a hierarchy of document templates and a hierarchy of documents: public class Template { ... } public class LetterTemplate extends Template { ... } public class OfficialLetterTemplate extends LetterTemplate { ... } public class CasualLetterTemplate extends LetterTemplate { ... } public class ContractTemplate extends Template { ... } public class EmploymentContractTemplate extends ...

14. Overwriting table problem    forum.hibernate.org

15. many to many supply table problem    forum.hibernate.org

I have a problem with many to many. Every data geting insert in to the DB but the supply table "PLANET_DBCOMP" is still empty. I dont know why please help me. Hibernate version: hibernate-2.1 Mapping documents: Not full I hope all you need. The planet:

16. problem on "table per class hierarchy" handling in    forum.hibernate.org

Hello, I am a new hibernate guy, could someone help me about the following peoblem. I have two tables, I am going to handling the inheritance with " table per class hierarchy" two tables: Users UserTypes --------------------------- ---------------------------- UserID (PK, int) |-----------> UserTypeID(PK, int) UserTypeID (FK, int) <---------| .... ... --------------------------- --------------------------- Subclass of Users: Doctors when UserTupeID = 1 Patients ...





17. Problem creating table(intermediate) using hibernate    forum.hibernate.org

Hibernate version: 2.1 Mapping documents: Code between sessionFactory.openSession() and session.close(): Full stack trace of any exception that occurs: Name ...

18. Strange problem with table per hierarchy and hascode    forum.hibernate.org

Hello there! I have a mapping using table per class hierarchy. I'm using fake names since I'm forbid to post real company code :( Like hibernate in action I have an abstract class billing details and 2 subclasses creditcard and bankacc My user has 2 sets (I do need them to be separated) Set creditcards Set bankaccs The mappings are straightforward: ...

19. Problem with self-table reference    forum.hibernate.org

I create a tree of categories. But when I try to take the root category exception rises. -1 in ParentId field means that this category is root of the tree. net.sf.hibernate.UnresolvableObjectException: No row with the given identifier exists: -1, of class: org.binarus.domain.PreparationsCategory at net.sf.hibernate.UnresolvableObjectException.throwIfNull(UnresolvableObjectException.java:38) at net.sf.hibernate.impl.SessionImpl.internalLoad(SessionImpl.java:1954) at net.sf.hibernate.type.ManyToOneType.resolveIdentifier(ManyToOneType.java:69) at net.sf.hibernate.type.EntityType.resolveIdentifier(EntityType.java:204) at net.sf.hibernate.impl.SessionImpl.initializeEntity(SessionImpl.java:2205) at net.sf.hibernate.loader.Loader.initializeEntitiesAndCollections(Loader.java:315) at net.sf.hibernate.loader.Loader.doQuery(Loader.java:305) at net.sf.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:133) at net.sf.hibernate.loader.Loader.loadEntity(Loader.java:911) at ...

20. Problem with table per concrete class    forum.hibernate.org

Hi all, I try to use Hibernate 3.0.5 to map inherited class with the method describled in the document "10.1.5. Table per concrete class". However, Hibernate always creates a table for my parent abstract class. Here is my sampe java code and mapping xml: [code] public abstract class Property { protected long propertyId; protected String name; public long getPropertyId() { return ...

21. Problem with nested table architecture    forum.hibernate.org

...

22. Denormalized Table per Class Hierarchy Problem    forum.hibernate.org

My database looks like this (yes, I know, but it's a legacy database): Code: EMP_ID|EMP_LEVEL_NAME|SLS_NBR|SLS_F_NAME|SLS_L_NAME|MGR_NBR |MGR_F_NAME|MGR_L_NAME|VP_NBR|VP_F_NAME|VP_L_NAME 1 |SLS |1 |BOB |SMITH |400 |STEVE ...

23. Problem Returning rows from table    forum.hibernate.org

Need help with Hibernate? Read this first: http://www.hibernate.org/ForumMailingli ... AskForHelp I have a query that returns 6 rows - which is correct - but each instance of PromoHeadingsHolder.class contains the data from row 1. I have tried many combinations, but same result. The PK on the table consists of the first 2 columns in the mapping document and the associated index ...

24. problem with legacy table    forum.hibernate.org

I have a legacy table with no primary key, just a unique index with five columns. Also some of this unique index columns are nulable I read that one solution is create a composite id with all columns, but when some column is nulable this solution fails Other solution is create a new column for primary key, but i can't modify ...

25. Table design problem    forum.hibernate.org

Hi all, I have a problem that's a bit unique and I'm wondering what's the best way to handle it using hibernate. Maybe some of you guys can help out. I have two tables: Table Persons: Belongs to a DB where I can only READ data, hence in my mapping file, it's marked as "mutable=false". This table contains data regarding people ...

26. many-to-many problem with same table    forum.hibernate.org

Hello, I've got a problem with a many-to-many relation on the same table. There is an operation-class which consists of predecessor and successor (both are operations as well) There are no problems in reading from the database, but when I want to add a new operation only the operation is saved and not the relations in table "presuc", which contains the ...

27. Problem clearing tables    forum.hibernate.org

Newbie Joined: Fri Jan 19, 2007 8:05 pm Posts: 2 Hi everybody, my problem is rather simple: how can I erase all data from a bunch of tables? We run a Java5/EJB3 application inside JBoss4.0.4.GA using Hibernate3 and a MySQL5 database. For some performance critical queries we also use JDBC calls. We have a JUnit4 test suite, each of the tests ...

28. many to many problem when have repeated cols in both tables    forum.hibernate.org

i have 2 tables.. table1 - primary key(a, b) table2 - primary key(a, c) i need a many-to-many relationship to create a table3 with attributes a,b,c table3 - primary key(a,b,c) but the attribute 'a' exists in the both tables and hibernate give me an error like this -> Repeated column in mapping for collection in a many-to-many relationship doesn't exists an ...

31. Problem with Table Hibernate    forum.hibernate.org

I use Hibernate 3.1.2 woth DB2 8.2 and Java 5 I have create table name Hibernate. wich stored the Hibernate-IDs This Table have one row with the name next_value and is a Integer-field. In the Mappings of the Tables I use the hilo Generatior to generate IDs But, when I start my application I become the following Error Message: 08:53:11,062 DEBUG ...

32. EntityBinder and @Table.appliesTo problem    forum.hibernate.org

Hi, I have a custom naming strategy providing the real table name of the table the classes are persisted to. My problem is that when I use the org.hibernate.Table annotation on a persisted class the appliesTo property must be hard-coded because when Hibernate resolves the annotations it does not use the naming strategy to obtain the actual name of the table. ...

33. HQL problem when using TABLE_PER_CLASS    forum.hibernate.org

@MappedSuperclass @Inheritance(strategy = InheritanceType.TABLE_PER_CLASS) public abstract class Parent implements Serializable { private int id; private int parentValue; private int childValue; @Id public int getId() { return id; } ...