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

James Taylor commented on PHOENIX-1883:
---------------------------------------

The REPEAT function is an interesting one because there's some room for 
optimization. For example, if the second argument is a constant, then the 
function will preserve ordering for the first argument. See SubstrFunction for 
a similar example. The benefit of setting orderPreserving correctly is that a 
query may be able to optimize out an ORDER BY. For example:
{code}
SELECT * FROM T ORDER BY REPEAT(pk1, 2);
{code}


> Implement REPEAT Function
> -------------------------
>
>                 Key: PHOENIX-1883
>                 URL: https://issues.apache.org/jira/browse/PHOENIX-1883
>             Project: Phoenix
>          Issue Type: Sub-task
>            Reporter: Naveen Madhire
>            Assignee: Naveen Madhire
>            Priority: Minor
>
> Implement REPEAT Function - String Built In Functions



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to