Re: [SQL] inheritance

2007-03-08 Thread Shane Ambler
Richard Broersma Jr wrote: Maybe then you'll add a table basket that has a foreign key to the fruit table... ;-) From the inheritance link: ... A serious limitation of the inheritance feature is that indexes (including unique constraints) and foreign key constraints only apply to single

Re: [SQL] inheritance

2007-03-08 Thread Richard Broersma Jr
> > it's my understanding that inheritance has become much stronger in 8.2, > although it still only inherits parts of the table. True. But from what I understand, the only new feature that was added to table-inheritance was the ability to ALTER a table so that it inherits another table. Befor

Re: [SQL] inheritance

2007-03-08 Thread chester c young
--- Richard Broersma Jr <[EMAIL PROTECTED]> wrote: > > > > Maybe then you'll add a table basket that has a foreign key to the > fruit > > table... ;-) > > From the inheritance link: > ... > A serious limitation of the inheritance feature is that ... it's my understanding that inheritance h

Re: [SQL] inheritance

2007-03-08 Thread Richard Broersma Jr
> > Maybe then you'll add a table basket that has a foreign key to the fruit > table... ;-) >From the inheritance link: ... A serious limitation of the inheritance feature is that indexes (including unique constraints) and foreign key constraints only apply to single tables, not to their in

Re: [SQL] inheritance

2007-03-08 Thread Shane Ambler
chester c young wrote: --- Greg Toombs <[EMAIL PROTECTED]> wrote: I'm trying to figure out how to nicely implement a C++ class-likesystem > > with PostgreSQL. Consider the following: Tables Fruit, Apple, Orange you can do this traditionally or through pg inheritance, although I do not think

Re: [SQL] inheritance

2007-03-08 Thread chester c young
> --- Greg Toombs <[EMAIL PROTECTED]> wrote: > > > I'm trying to figure out how to nicely implement a C++ class-likesystem > > with PostgreSQL. Consider the following: > > Tables Fruit, Apple, Orange you can do this traditionally or through pg inheritance, although I do not think inheritance is w

Re: [SQL] Inheritance (general hints wanted)

2005-09-20 Thread Achilleus Mantzios
Judging from the replies i got, it seems that inheritance is even less used than i initially thought. I think that the OO term is a little too much advertised in pgsql advocacy various acts, than actually engineered. However, OO in pgsql besides being a traditionally cool acronym, it also *could

Re: [SQL] Inheritance (general hints wanted)

2005-09-20 Thread Achilleus Mantzios
O Achilleus Mantzios έγραψε στις Sep 20, 2005 : > > Hi, > > I think i have reached a point in my PgSQL years > that i am seriously thinking of using inheritance. > > The situation is simple: An new entity (tanker vessels crew) > is about to be modeled, and i suspect > there will be a future nee

Re: [SQL] Inheritance (general hints wanted)

2005-09-20 Thread thomas.silvi
Hi, I am not an expert but in object conception, a design pattern exists for the case you describe. I don't remember which one. The idea is to add an attribute that references the job of the employee. The inheritance is not on the side of the employee but on the side of the job. So if

Re: [SQL] Inheritance or no inheritance, there is a question

2003-08-20 Thread David Fetter
Josh Berkus <[EMAIL PROTECTED]> wrote: > Vernon, > >> What is the best solution for this DB scheme problem? > > Have you considered not using inheritance? As a relational-SQL geek myself, > I'm not keen on inheritance -- I feel it mucks up the relational model. Not > everyone agrees with me,

Re: [SQL] Inheritance or no inheritance, there is a question

2003-08-19 Thread Josh Berkus
Vernon, > Thanks for your suggestion. I haven't thought this structure, to compose a > table with another one. That probably is the best solution I can have. With > this approach, I need to have two tables for B. As a result, all queries, > insertion, update, deletion, of B need to operate on thes

Re: [SQL] Inheritance or no inheritance, there is a question

2003-08-18 Thread Josh Berkus
Vernon, > What is the best solution for this DB scheme problem? Have you considered not using inheritance? As a relational-SQL geek myself, I'm not keen on inheritance -- I feel it mucks up the relational model. Not everyone agrees with me, of course. Personally, I'd suggest the following s

Re: [SQL] inheritance problems

2002-06-14 Thread Stephan Szabo
On Fri, 14 Jun 2002, Matt wrote: > I have a parent with two columns, the primary key; several children > inherit these columns. > > I can see all the childrens primary keys in the parent. however I can't > reference data in the parent table that was entered into a child. I get > a referential int

Re: [SQL] Inheritance Semantics

2001-04-09 Thread Bruce Momjian
> Could someone (Chris Mead?) post an update on the status of fixing > PostgreSQL's inheritance semantics in the following ways: > > Has a decision been made to implementing true inheritance via INHERITS or an > alternative keyword? > > By true inheritance, I mean first and foremost that any que

Re: [SQL] Inheritance

2000-05-30 Thread Peter Eisentraut
On 30 May 2000, Christophe Labouisse wrote: > I have a table (A) with a few "sibbling" tables (B and C for You probably mean "child" tables. > instance). When I make the following query : select id from A* where > [condition] pgsql returns ids taken from A, B or C (which is what I > want). Is t