[ 
https://issues.apache.org/jira/browse/JENA-72?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13049950#comment-13049950
 ] 

Andy Seaborne commented on JENA-72:
-----------------------------------

I've parameterized the tests and added more tests.

If the conclusion is to use this patch, I'll apply it but you (Paolo) ended 
with a question with a question on JENA-69 so I'm not sure if this is a 
suggested approach or a proposed fix.

IMHO, a custom parser is fine.

Changing Tokenizer(Text|Bytes) to (optionally) expose whitespace is also fine 
but probably (1) much more work (2) odd in that it is not generally used.

> TSVInput infinite loop and optional binding values not handled
> --------------------------------------------------------------
>
>                 Key: JENA-72
>                 URL: https://issues.apache.org/jira/browse/JENA-72
>             Project: Jena
>          Issue Type: Bug
>          Components: ARQ
>            Reporter: Laurent Pellegrino
>              Labels: tsvinput
>         Attachments: JENA-72_ARQ_r1136132.patch
>
>
> TSVInput that has been proposed in JENA-69 contains two bugs:
> 1) When you attempt to read an empty ResultSet (i.e. a ResultSet that contain 
> no binding) the code will enter in an infinite loop. This issue is really 
> simple to solve.
> 2) Optional binding values are not supported, especially with the following 
> ResultSet:
> (resultset (?a ?b ?c)
>     (row (?a 1) (?c 4))
>     (row (?a 1) (?b 2) (?c 3)))
> it will be serialized as:
> a....b....c
> 1..........4
> 1....2....3
> When we call tokenizer.next(), we get the next token. The problem is that we 
> are not aware that the tokenizer has consumed two separators (\t), and we 
> cannot detect that the value 4 is associated to the variable c.
> Any idea to handle it?

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to