aspose file tools*
The moose likes JDBC and the fly likes Table Inheritence  in oracle? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » JDBC
Bookmark "Table Inheritence  in oracle?" Watch "Table Inheritence  in oracle?" New topic
Author

Table Inheritence in oracle?

scott miles
Ranch Hand

Joined: Jun 16, 2011
Posts: 70
Could anybody brief about Table inheritence in oracle with simple example. Tried to look on different website
but did not get any concrete simple example? say if we have employee class in java and Manager class is extending
employee. Now i want to insert the values in manager class. then some values should go to employee table too along with manager table. could some body help me how we can achieve this thru JDBC?
chris webster
Bartender

Joined: Mar 01, 2009
Posts: 1651
    
  14

Tables are not classes or objects so they do not inherit anything. You could have a column in your table to distinguish managers e.g. Employee_type. This will allow you to put all the records in one table but identify managers as a subset. If you are going to use a relational database like Oracle, you need to find out why relational data modelling is different from OO modelling.


No more Blub for me, thank you, Vicar.
 
Don't get me started about those stupid light bulbs.
 
subject: Table Inheritence in oracle?