On Sun, Dec 11, 2016 at 12:28 PM, Andy Seaborne <[email protected]> wrote:
Which tests? ARQ, SPARQL ones? Graph ones? > Graph tests. I am only working on ensuring that the base graph storage works as expected. The implementation should work with the wider datasetgraph and others but at this stage I want to make sure that the add, delete, query work as expected at the low level. > The notion of Capabilities.handlesLiteralTyping isn't particularly > relevant to SPARQL which has both exact term matching (SameTerm) and value > matching (in FILTERS, =, <, >). It is not part of the RDF specs either - > it's a form of entailment. > > Lexical-space, value-space is part of SPARQL. The per-graph idea of > literal typing has been overtaking by specs - it's a very old feature from > a time when RDF was just coming into being and RDF wasn't well connected to > the numerical work in XML-land. > > handlesLiteralTyping is only called from test cases in the code base. I > don't remember seeing it in any support questions for many years. > > We should arrange to evolve it away. > In the graph contract tests there is a test where (if handlesLiteralTyping is set) the test verifies that 42 as a typed literal created with a java type int, byte, short or long match 42^^xsd:integer What I think I am reading above is that this doesn't matter and that the SPARQL level will handle it. But that does not seem correct to me. So if we look at the TDB strategy for storage does it match 42^^xsd:int with a query for 42^^xsd:byte or 42^^xsd:long? If so what lexical value does it return? Does TDB always convert to integer or does it use long? What does it do if a value crosses the MAX_VALUE threshold? I am trying to figure out how to do this for the Cassandra storage and I think the answer may be to add a numeric column that would be populated with any of the "integer" numeric types, though I was thinking perhaps a BigDecimal would work for all the data types and would make the scanning for ranges easier (as you mentioned before). For string literals I might store the text without language tag in another column for ease of scanning as well, but this may not make sense. I still have to look at how text queries might be implemented. thx, Claude -- I like: Like Like - The likeliest place on the web <http://like-like.xenei.com> LinkedIn: http://www.linkedin.com/in/claudewarren
