Re: Object-oriented thinking in SQL context?

From: <cimode_at_hotmail.com>
Date: Wed, 10 Jun 2009 05:10:48 -0700 (PDT)
Message-ID: <f371d9bc-967c-4853-9f15-485778db21c0_at_h2g2000yqg.googlegroups.com>


On 10 juin, 13:15, dr.coff..._at_gmail.com wrote:
> On 10 Jun, 00:12, "Walter Mitty" <wami..._at_verizon.net> wrote:
>
>
>
> > <dr.coff..._at_gmail.com> wrote in message
>
> >news:35fe9916-b423-49e4-95f4-b42bf672a4c7_at_x5g2000yqk.googlegroups.com...
>
> > >That's what confused me. The general concepts are *similar*
> > >to concepts from OO, but not the same. I suppose the main
> > >difference is that objects are local collections of different
> > >attributes, while in relational databases the objects are
> > >'disassembled' and the attributes distributed over the
> > >various tables.
>
> > If the mapping between OO concepts and RM concepts were simple,  someone
> > would have, by now, written a book that ties the two of them together, and
> > explains both patterns in terms that makes sense. to someone coming from one
> > pattern or the other.  To my knowledge, there is no such book.  I'm going to
> > echo something Bernard said in another response.
> > Better minds than mine have attempted to reconcile the OO way of thinking
> > and the RM way of thinking with each other.  By their own reckoning,  their
> > attempts have been unsuccessful.
>
> I can see your point, now that Bernard and you kindly have
> taken the time to explain it. Again, the concepts are so
> *similar* that it's an obvious idea to anyone coming from the
> OO side to at least ask why they aren't expressed in OO form.
> And again, I start to get an impression what the problem is:
>
> OO philosophy is founded on 'encapsualization', where attributes
> are collected into 'objects' that make some sort of sense in
> the problem (business) domain. Relational databases are all
> about breaking that encapsualization, to efficiently search
> for information.

As a remark, the relational model is not just about *tricks* and *stuff* that can be noticed *here* and *there*. Relational model is a direct application of math. This is a fundamental difference from OO *mindset* (if one accepts it would make sense to compare them) which has a sloppy and obscure fundamental fundation. From the perspective of RM, encapsulation is synonymous with accepting low level computing as a rule. Which is one of the reason they are difficult to compare.

> However, since the problem domain is the same, the analysis
> starts out in the same way (which was what confused me), but
> the routes towards solutions and implementations are different.
>
> > So you really shouldn't expect to reduce RM to a pattern that you already
> > know.  And you shouldn't expect, based on your success with OO up to this
> > point,  to be able to treat RM as something that can be marginalized as
> > either a specialized niche or a trivial development.  It is neither.
>
> Oh, I never said RM is trivial! I only said the building
> blocks are, which means the inter-relations between tables
> that are trivial when seen in isolation, become complex.
>
> A brick might be trivial; A structure built from bricks,
> like Hagja Sophia, is not.
>
>
>
> > Possibly the best person to speak to this would be Marshall.  Marshall is a
> > regular here who spend at least ten years as an OO programmer before going
> > over to the RM side.  He might be able to relate to what you do and do not
> > understand at your present stage.
Anybody who would make the effort of educating himself *seriously* on relational model would not do otherwise. That is what several people tried to encourage you to do. That is another, some would say bluntly genuine and different, but genuine nevertheless, to help you...

You seem to fail to understand that...Anyway good luck in your work...

Regards... Received on Wed Jun 10 2009 - 14:10:48 CEST

Original text of this message