spaziocodice / SolRDF

An RDF plugin for Solr
Apache License 2.0
113 stars 20 forks source link

java.text.ParseException: Unparseable date: "2008-06-08" #94

Closed agazzarini closed 8 years ago

agazzarini commented 9 years ago

Using the BSBM generated dataset, the following query, that involves a DateTime datatype:

SELECT * 
WHERE {     
?s <http://purl.org/dc/elements/1.1/date> ?o .     
?s <http://purl.org/dc/elements/1.1/publisher> ?o.    
}   

Raises the following exception:

Caused by: java.text.ParseException: Unparseable date: "2008-06-08"
    at java.text.DateFormat.parse(DateFormat.java:357)
    at org.gazzax.labs.solrdf.graph.standalone.FieldInjectorRegistry$4.addFilterConstraint(FieldInjectorRegistry.java:120)
    ... 53 more

The problem seems to be the DateFormat used in FieldInjectionRegistry, which doesn't allow optional parts in date pattern.

VIP: This error has been detected on the local graph family, and once fixed, should be applied also to cloud family.

agazzarini commented 9 years ago

Issue has been fixed in "issue_89" branch...I will merge that tomorrow

agazzarini commented 8 years ago

Pull request, related with this issue, from branch "issue_89" has been merged