design « Association « JPA Q&A





1. Multiple join associations in hibernate    stackoverflow.com

My question is related to database design and also how to model that design in Hibernate. I have two tables with the following primary keys:

BLOCK (BLOCK_ID)
BLOCK_SHP (BLOCK_ID, SHAPE_VERSION)
BLOCK to BLOCK_SHP is ...

2. How to best design association table that stores infos?    forum.hibernate.org

how to best design the mapping for the following problem: I've got 2 tables: TRAINING_SESSION --------------------------- ID1 INFO and STATE --------------------------- ID2 NAME I need to store the amount of people getting a training per State. I've got an association table (say EFFECTIVES) that's reference both table and that store the amount of people participating to the training per state: EFFECTIVES ...

3. Ternary Association Design    forum.hibernate.org

Hi guys, I'm using latest version of Hibernate here's what I wanna do and how I figure out I should implement the mapping: I have a bottom-up approach in my app, this is why i'm starting from the Tables I want to have a table A that can have a reference to B OR C. As I don't wan't to use ...

4. Bad database design with many-to-many associations?    forum.hibernate.org

Hello All, Here is my question... In creating the association table for a many-to-many relationship, why doesn't hibernate use the primary keys of the two tables for the composite key of the association table? Note: I have only seen this problem when I need an Association Class for attributes such as Quantity, ItemPrice, or Date... I have not seen this problem ...