Re: [GENERAL] Polymorphic delete help needed

2007-07-06 Thread PFC
I am doing a project using Ruby On Rails with PostgreSQL as the database. I have not seen the term polymorphic used with databases except with Rails so I will quickly describe it. Instead of holding just an id as a foreign key, the record holds a type field which is a string and an id. The

Re: [GENERAL] Polymorphic delete help needed

2007-07-06 Thread Perry Smith
On Jul 6, 2007, at 2:31 AM, PFC wrote: I am doing a project using Ruby On Rails with PostgreSQL as the database. I have not seen the term polymorphic used with databases except with Rails so I will quickly describe it. Instead of holding just an id as a foreign key, the record holds a type

Re: [GENERAL] Polymorphic delete help needed

2007-07-06 Thread David Fetter
On Thu, Jul 05, 2007 at 09:56:12PM -0500, Perry Smith wrote: I am doing a project using Ruby On Rails with PostgreSQL as the database. I have not seen the term polymorphic used with databases except with Rails so I will quickly describe it. You have now :)

Re: [GENERAL] Polymorphic delete help needed

2007-07-06 Thread PFC
O Here is how I implemented something very similar (in PHP) : - Node class and several derived classes. - nodes table which contains the fields for the base class with node_id as a PK and a field which indicates the class - nodes_*** tables which contain the extra fields for

Re: [GENERAL] Polymorphic delete help needed

2007-07-06 Thread Perry Smith
On Jul 6, 2007, at 8:01 AM, David Fetter wrote: On Thu, Jul 05, 2007 at 09:56:12PM -0500, Perry Smith wrote: I am doing a project using Ruby On Rails with PostgreSQL as the database. I have not seen the term polymorphic used with databases except with Rails so I will quickly describe it.

Re: [GENERAL] Polymorphic delete help needed

2007-07-06 Thread Perry Smith
On Jul 6, 2007, at 8:23 AM, PFC wrote: The advantage of my approach is that : [ snip -- all very good stuff ] I think I can make something like this into Rails fairly easy. Hm, another reason why I don't really like the Rails approach... do they at least use unique IDs ? Please

Re: [GENERAL] Polymorphic delete help needed

2007-07-06 Thread David Fetter
On Fri, Jul 06, 2007 at 08:39:50AM -0500, Perry Smith wrote: On Jul 6, 2007, at 8:01 AM, David Fetter wrote: On Thu, Jul 05, 2007 at 09:56:12PM -0500, Perry Smith wrote: I am doing a project using Ruby On Rails with PostgreSQL as the database. I have not seen the term polymorphic used

Re: [GENERAL] Polymorphic delete help needed

2007-07-06 Thread Perry Smith
On Jul 6, 2007, at 10:36 AM, David Fetter wrote: At some point, you're going to realize that Rails is the problem, not the solution. It's written by people who do not understand what a shared data store is and reflects problems inherent in its native database platform: MySQL 3.23. Thats

Re: [GENERAL] Polymorphic delete help needed

2007-07-06 Thread Alexander Staubo
On 7/6/07, David Fetter [EMAIL PROTECTED] wrote: At some point, you're going to realize that Rails is the problem, not the solution. It's written by people who do not understand what a shared data store is and reflects problems inherent in its native database platform: MySQL 3.23. This is

[GENERAL] Polymorphic delete help needed

2007-07-05 Thread Perry Smith
I am doing a project using Ruby On Rails with PostgreSQL as the database. I have not seen the term polymorphic used with databases except with Rails so I will quickly describe it. Instead of holding just an id as a foreign key, the record holds a type field which is a string and an id.