LinkedDataFragments / Client.js

[DEPRECATED] A JavaScript client for Triple Pattern Fragments interfaces.
http://linkeddatafragments.org/
Other
92 stars 35 forks source link

STR operator supported? #35

Closed pheyvaer closed 7 years ago

pheyvaer commented 7 years ago

When executing a query with STR in a FILTER I don't get neither a response or error. The fucntions of results.on('data') and results.on('end') are never called. When trying to use STRSTARTS I get the error that this operator is not supported, so I guess STR should work then?

pheyvaer commented 7 years ago

Might be related to #30?

mielvds commented 7 years ago

it is, although str should work: https://github.com/LinkedDataFragments/Client.js/blob/master/lib/util/SparqlExpressionEvaluator.js#L156

pheyvaer commented 7 years ago

Indeed. I tried again and noticed that it has to check > 40.000 triples. So this is why it is taking so long. Something else though, should it not be return isLiteral(a) ? literalValue(a) : '"' + a + '"';, because str should return the literal value. str("\"Ghent\"@en") should be the same as str("\"Ghent\""), no?

mielvds commented 7 years ago

Yes, as is the case in the more spec-compliant https://github.com/LinkedDataFragments/Client.js/blob/feature-more-filters/lib/util/SparqlExpressionEvaluator.js#L282

pheyvaer commented 7 years ago

OK, I'll close this issue then as it will be resolved when merging #30.