• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Bear Bibeault
  • Junilu Lacar
Sheriffs:
  • Jeanne Boyarsky
  • Tim Cooke
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • salvin francis
  • Frits Walraven
Bartenders:
  • Scott Selikoff
  • Piet Souris
  • Carey Brown

Problem with fetching mapped entities

 
Ranch Hand
Posts: 954
4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi

Could you please help me to solve one JPA issue? I trying to make 1 project for learning but struck here.

I have 3 entities with OneToMany relation like below:



Now What i want is for a particular period i want to fetch all the related tags and all the related transactions. But whenever i query it always return Period and Tag but transactions is empty.

This query returns only period/tag. Transaction are empty.


But when i used join than it will fetch values in pairs

 

I want result like 1 with transactions value. Please help me.
 
Tushar Goel
Ranch Hand
Posts: 954
4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Very strange it works fine for H2 database but when i use postgress it doesn't work. I only changed properties file and no other changes done
 
    Bookmark Topic Watch Topic
  • New Topic