aspose file tools*
The moose likes EJB and other Java EE Technologies and the fly likes getting information from cascade Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "getting information from cascade" Watch "getting information from cascade" New topic
Author

getting information from cascade

addrian brilianda
Greenhorn

Joined: May 07, 2012
Posts: 6
I have 2 tables.. one table provide the province describe with province ID for the PK..another table have city describe where it have the coloumns of province ID.. and then i want to call the city with the specified province ID... ex call the city where province ID is 1..... how to make the queries of it with JPA and EJB??
Jeanne Boyarsky
internet detective
Marshal

Joined: May 26, 2003
Posts: 29287
    
140

Everything you need is in one table making it easy. You need a named query for your City entity with the province id in the where clause. Search for named queries for some examples and then post back here if you have more questions/get stuck.


[Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Blogging on Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, OCAJP, OCPJP beta, TOGAF part 1 and part 2
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: getting information from cascade
 
Similar Threads
OneToMany not by ID
JQuery table manipulation
Where are U from?
preparedStatement
Please suggest