W3C home > Mailing lists > Public > semantic-web@w3.org > November 2012

Re: Counting datatypes per property

From: Heiko Paulheim <paulheim@ke.tu-darmstadt.de>
Date: Thu, 08 Nov 2012 12:22:47 +0100
Message-ID: <509B9607.5090505@ke.tu-darmstadt.de>
To: Martin Voigt <martin.voigt@tu-dresden.de>
CC: semantic-web@w3.org, Dominik Wienand <dominik.wienand@online.de>
Hi Martin,

DATATYPE is a built-in operator in SPARQL:
http://www.w3.org/TR/rdf-sparql-query/#func-datatype

We are not so much interested in the schema definition, but rather in 
the *actual* use of a property, e.g., in cases where it does not have a 
defined range, or where it is used in an "illegal" way that is not 
foreseen by the schema.

Best,
Heiko


Am 08.11.2012 12:16, schrieb Martin Voigt:
> Hi Heiko,
>
> we use the following simple SPARQL query which works fine so far.
>
> SELECT ?r (COUNT(?r) AS ?num)
> WHERE {
>     ?x a owl:DatatypeProperty ;
>         rdfs:range ?r .
> }
> GROUP BY ?r
>
> Where is the DATATYPE function defined?
>
> Regards,
> Martin
>
> Am 08.11.2012 11:43, schrieb Heiko Paulheim:
>> Hi all,
>>
>> we are trying to analyze datatype properties by the datatype they use.
>> Our first idea was to use a simple SPARQL query per property, however,
>> the following does not do what I would expect it to do:
>>
>> SELECT COUNT(?x) DATATYPE(?y) WHERE {?x dbpprop:utcOffset ?y}
>>
>> This query does not group all entries with, e.g.,
>> <http://www.w3.org/2001/XMLSchema#int> in one row. Why not? What am I
>> doing wrong here?
>>
>> Best regards,
>> Heiko
>>
>>
>

-- 
Dr. Heiko Paulheim
Knowledge Engineering Group
Technische Universitšt Darmstadt
Phone: +49 6151 16 6634
Fax:   +49 6151 16 5482
http://www.ke.tu-darmstadt.de/staff/heiko-paulheim
Received on Thursday, 8 November 2012 11:23:21 GMT

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