0
votes
0answers
6 views
HQL:Implicit Association joining not working
I am using Hibernate 3.2.5 for my application.
I have a Dept table and an Employees table.
Dept.java
private int deptId;
private String deptName;
private Map empMap = new HashMap();
//Getters and ...
1
vote
1answer
30 views
How to insert specific column of Excel into Database
I have an Excel sheet with 200+ column names and each column has a header name. I have to fetch all the header names first from the Excel sheet using Java and pass them into Oracle DB. The DB returns ...
0
votes
0answers
17 views
Left_Join on same tables in Hibernate Criteria API
I have a table and a class marked as @Entity with @Table(name="Employee")
It has two fields, Id and Name
i want to do left join on same table like,
`
Select t2.name, count(*)
from ...
0
votes
0answers
13 views
Hibernate Returning Multiple Outer Entities
I have the following entities:
Survey
Response
ResponseQuestion
Question
Survey has a one-to-one association with Response.
Response has a one to many association with ResponseQuestion, which has ...
0
votes
1answer
15 views
Hibernate: unidirectional, remove many-to-many association
this is my scenario,
i have SubForum class, that holds set of moderators, each entity int that set is User class.
this is the mapping of the SubForum
<class name="server.Subforum">
<id ...
1
vote
3answers
41 views
Hibernate: java.lang.ClassCastException: [Ljava.lang.Object; cannot be cast to database.entity.Dokumenty
I have little problem :( When I try do this:
List<Dokumenty> dokumentyList =
(List<Dokumenty>)dokumentyDAO.getDokumentyByTrasy(((Trasy)routeComboBox.getSelectedItem()).getId());
...
0
votes
0answers
7 views
How to disable EntityPrinter output in Hibernate without changing log level?
I am encountering java.util.ConcurrentModificationException while commiting JPA transaction.
The stacktrace shows that it was from EntityPrinter:
Caused by: java.util.ConcurrentModificationException
...
0
votes
1answer
24 views
Passing date to hql query from Java
I am trying to figure out how to get a date that is exactly one year less than the current date and pass it as a parameter to HQL.
I tried to use Calendar. But I am lost in converting this to right ...
0
votes
0answers
68 views
String or Date?
So I have and issue somewhere between my Java code, and MySQL database where Hibernate gets upset with my input for dates. So I was tossing around the idea of scrapping the Date data type and just ...
0
votes
0answers
14 views
playframework hibernate immutable entities and version changing by merge
I want to make sure that
I may use/to have immutable entities with Hibernate (use play-framework)
That optimistic strategy works for my entities (version is changing) when I save/marge them back to ...
0
votes
0answers
18 views
EntityManager ERROR while persist
I tried to Insert a Object of my "OPOS" Entity class to my Microsoft SQL Server 2008 10.00.2531.00; SP1 with hibernate ORM.
Opos.java
...
public class Opos implements Serializable
{
private static ...
1
vote
1answer
14 views
Restrictions to lazy loaded object properties in hibernate
There are two model classes.
public class Register implements Serializable{
@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
@Column(name = "id", unique = true, nullable = false)
...
-2
votes
0answers
17 views
duplicate class: ch.intercard.reportmanager.domain.Report_ and OutputFormat_
I entered a project, where I only had source code and tomcat shared libraries.
This project includes also hibernate. For this reason when ant's compile target is run, it reads to folder as /src ...
2
votes
3answers
29 views
Active record pattern with Hibernate
I am developing a fairly simple web app using Spring MVC + JSP + Hibernate. To get started I followed this tutorial:
http://www.cavalr.com/blog/Spring_3_and_Annotation_Based_Hibernate_4_Example
This ...
0
votes
1answer
25 views
Hibernate - List referencing superclass
I have a question regarding hibernate in regards to inheritance. If I have the following classes:
@Entity
@Table(name = "people")
@Inheritance(strategy=InheritanceType.JOINED)
...