-------- Original Message --------
Subject: Re: Fwd: issue in integrating relfinder with stanbol
Date: Fri, 07 Jun 2013 09:44:55 +0100
From: Andy Seaborne <[email protected]>
To: [email protected]

1/ SELECT ?s ?l count(?s) as ?count

Bad syntax

It's properly:

SELECT ?s ?l (count(?s) as ?count)

See

http://www.sparql.org/query-validator.html

which is using the grammar used to make the spec HTML.

2/ bif:contains is Virtuoso magic for text matching.

(The bif: does not need to be declared so it's not even legal syntax).

<bif:contains>  makes it legal syntax but only virtuoso implements this
way of doing text matching.

any other system will see a property which is unlikely to match anything.

        Andy



On 07/06/13 07:49, Minto van der Sluis wrote:
Hi,

Isn't the count function SPARQL 1.1?

Currently the released version of Clerezza supports only SPARQL 1.0.
However the current snapshot version (trunk) has support for SPARQL 1.1.
When will this be released? Unfortunately I don't know.

Regards,

misl

Op 7-6-2013 8:23, Rupert Westenthaler schreef:
Hi Manish,

Stanbol uses the Clerezza SPARQL implementation. Therefore questions
related to SAPRQL query support are better targeted to the Clerezza
community.

But AFAIK count is not supported by the SAPRQL standard, but an
extension supported by some SPARQL implementations (e.g. Jena) so most
likely this is simple because Clerezza does not support it.

best
Rupert

On Thu, Jun 6, 2013 at 4:23 PM, Garg, Manish <[email protected]> wrote:
HI Team

we are trying to integrate relfinder with stanbol. We have pointed it to
stanbol SPARQL endpoint setup locally.

We are facing some issues which are explained below. If you could please
provide some inputs on resolving these issues, will be a great help.

When i search for entity "India" in relfinder, it doesnt return any
results. It creates a query which is mentioned below
  SELECT ?s ?l WHERE {  ?s <http://www.w3.org/2000/01/rdf-schema#label>
?l .FILTER
regex(?l, 'india', 'i').FILTER (lang(?l) = '' || langMatches(lang(?l),
'en')).} LIMIT 20

but data is present there in stanbol.

If we modify the query a little as highlighted below

SELECT ?s ?l WHERE {  ?s <http://www.w3.org/2000/01/rdf-schema#label>
?l .FILTER
regex(str(?l), 'india', 'i').FILTER (lang(?l) = '' || langMatches(lang(?l),
'en')).} LIMIT 20

and execute it on stanbol SPARQL endpoint directly, then it returns the
desired data.

The other problem we are facing that stanbol sparql enpoint doesn't support
count function in SPARQL query. When i try to execute the query formed by
relfinder for dbpedia on stanbol sparql endpoint then it shows "invalid
query"

SELECT ?s ?l count(?s) as ?count WHERE {?someobj ?p ?s .  ?s <
http://www.w3.org/2000/01/rdf-schema#label> ?l .?l bif:contains "'india'" .
FILTER (!regex(str(?s),
^http://dbpedia.org/resource/ategory:')<http://dbpedia.org/resource/Category:')>
).FILTER (!regex(str(?s), '^http://dbpedia.org/resource/List')).FILTER
(!regex(str(?s), '^http://sw.opencyc.org/')).FILTER (lang(?l) = '' ||
langMatches(lang(?l), en')).FILTER (!isLiteral(?someobj)). }ORDER BY
DESC(?count) LIMIT 20

but when i remove count function then it executes.

Any help in this regard will be appreciated.


--

Regards****

Manish Garg

--

"This e-mail and any attachments transmitted with it are for the sole use
of the intended recipient(s) and may contain confidential , proprietary or
privileged information. If you are not the intended recipient, please
contact the sender by reply e-mail and destroy all copies of the original
message. Any unauthorized review, use, disclosure, dissemination,
forwarding, printing or copying of this e-mail or any action taken in
reliance on this e-mail is strictly prohibited and may be unlawful."


--
| Rupert Westenthaler             [email protected]
| Bodenlehenstraße 11                             ++43-699-11108907
| A-5500 Bischofshofen






Reply via email to