W3C home > Mailing lists > Public > public-rdf-dawg-comments@w3.org > January 2007

Re: SPARQL prefixes and local parts

From: Jiri Dokulil <dokulil@gmail.com>
Date: Mon, 8 Jan 2007 19:17:10 +0100
Message-ID: <6a8224ab0701081017t2b4c0c33n7cb5162a54dfe3bd@mail.gmail.com>
To: public-rdf-dawg-comments@w3.org

For the same reason, I think # should be allowed as well.
I've already used a two-level structure that shared a common
namespace, but the two levels were separated by #.
For instance:
http://example.org/foo/bar/class1#attribute1
http://example.org/foo/bar/class1#attribute2
http://example.org/foo/bar/class2#attribute2
http://example.org/foo/bar/class2#attribute3

But in the current SPARQL grammar, it is necessary to define different
namespace prefixes for each "class" instead of using simple
ns:class2#attribute2

Note: This class-attribute structure may be a bad way to create an
ontology, but the source of the data forced it to be this way.

Jiri Dokulil

On 1/8/07, mark.d.wood@kodak.com <mark.d.wood@kodak.com> wrote:
>
> The current SPARQL specification states the following for prefixed names:
>
> The PREFIX keyword associates a prefix label with an IRI. A prefixed name is
> a prefix label and a local part, separated by a colon ":". It is mapped to
> an IRI by concatenating the local part to the IRI corresponding to the
> prefix. The prefix label may be the empty string.
>
> The grammar for local parts does not allow slashes in the name.
>
> I would like to suggest that local parts should in fact allow for slashes in
> the local part of the name.   This allows one to define prefixes that are
> basically the root of some structure.
>
> For example, one might wish to define a prefix
>
> PREFIX ex1:  <http://www.example.org/schemas/Concept1>
> PREFIX ex2:  <http://www.example.org/schemas/Concept1>
>
> and therefore specify abbreviated IRIs such as:
>
> ex1:SubConceptA/SubConcept1
>
> and
>
> ex2:SubConceptB/SubConcept2
>
> Without this ability, one must either define a very flat namespace, or
> define separate prefixes for every concept.
>
> -Mark Wood
>
Received on Monday, 8 January 2007 18:17:34 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 8 January 2008 14:14:51 GMT