[
https://issues.apache.org/jira/browse/JENA-111?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13098308#comment-13098308
]
Paolo Castagna edited comment on JENA-111 at 9/6/11 11:35 PM:
--------------------------------------------------------------
Sara's proposal seems a good idea to me and I did not spotted initially.
Are there other situations where an algebra operator between slice and order
will inhibit the optimizations in JENA-89 and JENA-109?
Given:
(slice X N
(distinct or reduced
(project (vars)
(order (cond)
PATTERN ))))
There are four possibilities:
1) slice order [DONE]
2) slice distinct|reduced order [DONE]
3) slice distinct project order [NEW]
4) slice project order [NEW]
1)
(slice X N
(order (cond)
PATTERN ))
==>
(slice X _
(top (X+N cond)
PATTERN ))
2)
(slice X N
(distinct or reduced
(order (cond)
PATTERN )))
==>
(slice X _
(top (X+N cond)
(distinct
PATTERN )))
3)
(slice X N
(distinct or reduced
(project (vars)
(order (cond)
PATTERN ))))
==>
(slice X _
(distinct
(project (vars)
(top (X+N cond)
PATTERN ))))
4)
(slice X N
(project (vars)
(order (cond)
PATTERN )))
==>
(slice X _
(project (vars)
(top (X+N cond)
PATTERN )))
Although, I am not 100% sure about 3) and 4).
was (Author: castagna):
> but, by using subSELECTs, you can write any sequence you want.
This line confused me, rather than clarify. My understand is that if we handle
the project we have covered all the possibilities between slice and order
algebra operators, right?
Sara's proposal seems a good idea to me and I did not spotted initially.
Are there other situations where an algebra operator between slice and order
will inhibit the optimizations in JENA-89 and JENA-109?
> Improving TopN optimization in case of an intermediate OpModifier
> -----------------------------------------------------------------
>
> Key: JENA-111
> URL: https://issues.apache.org/jira/browse/JENA-111
> Project: Jena
> Issue Type: Improvement
> Components: ARQ
> Reporter: Sara Magliacane
> Assignee: Paolo Castagna
> Priority: Minor
> Labels: arq, optimization
> Attachments: topk_project.patch
>
>
> In the TopN optimization (Jena-89) it would be useful to handle also the
> case in which there are some other OpModifiers (I think they are the only
> category of Ops that can be in that position in the tree) between Slice and
> Order By, for example OpProject:
> (slice _1
> (project ?s ...
> (order by <condition>
> ->
> (project ?s ...
> (top 1 <condition>
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira