Re: Queries and OO
From: Doc O'Leary (droleary.usenet_at_2005.subsume.com)
Date: 01/09/05
- Next message: Ron Jeffries: "Re: how many bugs do you find and correct during TDD?"
- Previous message: Phlip: "Re: how many bugs do you find and correct during TDD?"
- In reply to: frebe: "Queries and OO"
- Next in thread: frebe: "Re: Queries and OO"
- Reply: frebe: "Re: Queries and OO"
- Reply: Daniel Parker: "Re: Queries and OO"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Sun, 09 Jan 2005 05:53:04 -0600
In article <1105187499.122160.231670@c13g2000cwb.googlegroups.com>,
"frebe" <fredrik_bertilsson@passagen.se> wrote:
> After some debates at this forum I have made the conclusion that the
> concepts of queries does not exists within OO. The only *correct* way
> to find objects is through other objects (including collection
> objects).
Your conclusion makes no sense. You firstly don't define what exactly
you consider a query (let me assume you mean something like SQL), nor do
you say why a database table/row/column cannot be considered objects.
You can easily get the same kind of query ability if your OO environment
supports introspection (so you can refer to attributes) and uniquing
(i.e., a master record of all objects).
> If I have a number of "orders", I can find them by id if
> first I put them into a map using id as they key. If I want to get them
> ordered by "delivery data", I have to put them into a sorted set. If I
> want a list of "orders" that come from a given "customer", "customer"
> need to have a list of "orders" that belong to it.
What's your point? If you have a number of "orders", you can only find
them by id in a database if you first put them into a table. To get
them ordered by "delivery data" you have to specify their sort ordering.
If you want the orders for a specific customer, duh, you have to specify
that customer!
- Next message: Ron Jeffries: "Re: how many bugs do you find and correct during TDD?"
- Previous message: Phlip: "Re: how many bugs do you find and correct during TDD?"
- In reply to: frebe: "Queries and OO"
- Next in thread: frebe: "Re: Queries and OO"
- Reply: frebe: "Re: Queries and OO"
- Reply: Daniel Parker: "Re: Queries and OO"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|