• 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

make a entity class rows read-only in JPA

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

I m able to get values using JPA when i have only mapped one table

Now when i have gone for mapping related tables i get the error



I m using [EclipseLink-0] (Eclipse Persistence Services - 2.0.1.v20100213-r6600)

In one of the child tables i have this code



What changes i have to do in this code to make the fields read-only

or are there any better workaround for not making these fields read only

Thanks

Pradyut

India
 
Ranch Hand
Posts: 553
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You are using the same foreign key field in both ManyToOne's, this makes no sense. You must use different foreign key fields for each relationship.

 
    Bookmark Topic Watch Topic
  • New Topic