1
vote
0answers
45 views

Hibernate beginner

I'm currently trying to learn to use Hibernate to store objects in a database. I've been working through a tutorial at https://netbeans.org/kb/docs/java/hibernate-java-se.html and I'm trying to ...
0
votes
1answer
24 views

Hibernate schema generation: same configurations, different behaviour

I am working on a project and have encountered a quite baffling issue. Some context: the project is a fairly standard Java 7 project using Maven 3.0.4 as build tool and spring (3.2.3.RELEASE) for ...
0
votes
1answer
33 views

JPQL union of two joins

I have two related entities, User and Message. Message has two field containing the User entity, recipient and sender. Can I do something like union of two joins, where I get the users from both ...
0
votes
1answer
53 views

Deadlock in a simple PL/pgsql stored procedure that updates a single row (called by Hibernate)

I wrote a simple stored procedure: CREATE OR REPLACE FUNCTION "public"."update_table01" ( int4, -- $1 (population) int2 -- $2 (id) ) RETURNS "pg_catalog"."void" AS $body$ BEGIN UPDATE ...
0
votes
0answers
50 views

how to map an array of custom type from postgres to java using hibernate

I am trying to map an array of custom type returned by a postgres procedure to the java I have a custom type in postgres as CREATE TYPE public.customtype_sample AS( sampleid bigint, ...
0
votes
1answer
35 views

database space quotas with hibernate and postgresql, limit database megabytes used per user

Good day/night to all of you. In our university project we have a database created by hibernate (using postgresql) having 17 tables(obejct). We need to post a limit to 4 object i.e. ...
0
votes
1answer
70 views

Issues with concurrent Transactions

I have a particular object in my db table. Users of my application can add details to that object via UI. If suppose the same object is selected by multiple users and all of them want to add details ...
0
votes
1answer
38 views

Auto generated domain class id with exceptions

Scenario: Domain class is created and inserted using the default Postgres sequence generator (with a custom dialect to create one sequence per table but I think this is irrelevant). Now, in some cases ...
0
votes
0answers
28 views

Exception in PostgreSQL function not catched in Java Hibernate

I am using the following PostgreSQL function to delete a record from a table in the DB. CREATE OR REPLACE FUNCTION deletesegment(segid bigint) RETURNS integer AS $BODY$ DECLARE ...
0
votes
1answer
32 views

Hibernate : Failed to create sessionFactory object.org.hibernate.InvalidMappingException

I am sorry if this is a duplicate of any existing question. Following is my employee bean. public class Employee { private int id; private String firstName; private String ...
0
votes
3answers
51 views

Hibernate executeUpdate() on PostgreSQL function

I am using hibernate with a function in PostgreSQL to update a record in the DB. Following is the PostgreSQL function, CREATE OR REPLACE FUNCTION updatesegment(segid bigint, segname text, ...
0
votes
0answers
22 views

hibernate which naming strategy is default

When researching how to implement a custom naming strategy (for table names only) I stumbled upon an inconsistency, which I can't resolve. (I'm using hibernate-core 3.6.6.Final on JBoss 6.1.0.Final ...
0
votes
1answer
25 views

Named Native Query, execute update statement

Can we create update statement using @NamedNativeQuery, @Entity @Table(schema = "public", name = "conversion_checker") @NamedNativeQueries({ @NamedNativeQuery(name="updateExpireStatus", ...
0
votes
1answer
33 views

Hibernate not saving Object in the Database?

I have the following problem, when trying to insert an object in the database Hibernate gets stuck, no error returned, the object is not saved correctly. Debugging it I found out that it hangs at ...
0
votes
1answer
31 views

HQL - Only return single object for each object property sorted by how recently the object was updated

I have a Model called PlaylistDayStats that is related to a Playlist Model. I'm trying to do the following query, but I don't want to return two PlaylistDayStats if they are related to the same ...

1 2 3 4 5 32
15 30 50 per page