W3C home > Mailing lists > Public > semantic-web@w3.org > January 2008

Re: plural vs singular properties (a proposal)

From: Andrew Newman <andrewfnewman@gmail.com>
Date: Mon, 7 Jan 2008 09:26:50 +1000
Message-ID: <2db5a5c40801061526k31077bbdmc0dd25fa8e62086@mail.gmail.com>
To: "Frank Manola" <fmanola@acm.org>, SWIG <semantic-web@w3.org>

On 06/01/2008, Garret Wilson <garret@globalmentor.com> wrote:
> Andrew,
>
> Andrew Newman wrote:
> > Predicates need not be repeated in order to store multiple values -
> > the idea of multiple values is rather arbitrary.
> ...
>
> But do you agree that, if we consider relation attributes to model RDF
> predicates, that relations do not allow predicates to be repeated?
>
> RDF, on the other hand, allows predicates to be repeated. That contrast
> is what I was trying to communicate, and about which I was trying to
> learn if there is any reason to be alarmed.
>

I may have missed this discussed in the above thread but isn't the
easiest way to represent RDF is just three columns, subject, predicate
and object (and it means no nulls).
subject        predicate         object
#somebook  dc:subject       "semantic web"
#somebook  dc:subject       "database"

What I was saying previously is that multivalued predicates can be
supported by just allowing sets of values (or lists or maps and so on)
- as I was saying don't limit what you think a type can be to
something like just a string or a URI.

For example (I've put the name of the attribute and then it's type as
a colon afterwards):
subject:URI                 dc:subject:URI
#somebook     <"semantic web", "database">

So that allows non-repeating predicates and multiple values and would
come out in RDF as two triples (hopefully that's obvious).

You can take that one step further (excuse the crappy ASCII representation):
triplesForSubject:<subject, map<predicate, set<object>>>
 #somebook, <<dc:subject, <"semantic web", "database">> <dc:author,
<"fred", "jim">>
   <dc:title, <"Some title">>
 #otherbook, <dc:subject, <rdf>>

> > Attributes can also be of type relations (Chapter 6 of Intro to
> > Database Systems and Chapter 12.6 has some notes on it).
> >
> > In your example you want to store to subjects for a book.  The
> > attribute type then becomes a set of strings (or whatever type your
> > want to choose for subjects of books).
> >
>
> Yes, I understand that. Date is quite happy with his revelation
> (apparently he didn't believe this was possible in earlier editions of
> the book) that an attribute can be of a relation type and its value can
> itself be a relation. But that doesn't mean I'm putting multiple values
> in a tuple for that column---I'm putting one value, which is itself a
> relation.
>

I'm confused by your distinction here.  A relational type has values
inside it - like a string has characters inside it.  You can search
strings and return values, a query language that supported relations
within relations would allow you to query on these values too.  From
what I can remember arbitrary data type support for a query language
is one of the prescribed features in Third Manifesto.

> Similarly, if I want multiple dc:subject predicates, I can make the
> value of type rdf:List. That doesn't mean I'm giving the predicate
> dc:subject multiple values---it just means that its single value holds
> multiple resources.
>
> But (unlike the relational model, I think) in RDF I also have the option
> to repeat the predicate if I want another dc:subject value! Isn't this
> in direct contrast to the relational model? I can't just put "repeat the
> predicate" to add another value on a relation, can I!
>
> Bijan (both on this list and off-line) tells me that I can just add
> another tuple in the relation with the additional dc:subject value (I
> guess Frank said that as well), and that this is semantically equivalent
> to "repeating the predicate" in RDF (I hope I didn't misstate you, Bijan).
>

These all just sound like syntactic differences to me.
Received on Sunday, 6 January 2008 23:26:57 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 21:45:20 GMT