|
Hello, sorry for asking again about a relevant question concerning GROUP_CONCAT but I think I found a problematic situation while I was running my queries. The previous question was this: http://answers.semanticweb.com/questions/20337/semantics-of-group_concat I have a case in my queries where I want to combine GROUP_CONCAT with UNION and the VALUES clause. AndyS suggested to use GROUP_CONCAT and UNION as following:
In this example, suppose we have for the ?variable1 and ?variable2 VALUES clauses bound to them with some values. Then something very strange happens. I get for ?var1 and ?var2 all the values that both ?variable1 and ?variable2 contain. So both ?var1 and ?var2 are identical containing all the bindings for both variables! I tested the query with FILTER (IN ()) and it work correctly. Also the results when I am not using GROUP_CONCAT and use UNION with VALUES are again correct. Is this a Jena bug with GROUP_CONCAT and VALUES? Thank you again for your help! Chris EDIT ADDED EXAMPLE:
The result from Jena is: (?var1 = http://dbpedia.org/resource/Peter, http://dbpedia.org/resource/John" ) -> [Root] and the same is the result for ?var2. |


Hard to tell without examples of the different things you have tried. It will depend on where in the query you put VALUES and FILTER(IN).
I read about the ParameterizedSparqlString on the Jena website. If I do not find any solution for the above question, would you advise me to also check this solution?
In general, which is better in terms of performance? Submitting a concatenated String as query to Jena or using Jena's ParameterizedSparqlString to build the query? I know that the simply String solution has security issues and so on, but in this case I am only interested in terms of performance. Is there any other approach?
Thanks again!