[
https://issues.apache.org/jira/browse/TAJO-343?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13842333#comment-13842333
]
Hudson commented on TAJO-343:
-----------------------------
FAILURE: Integrated in Tajo-trunk-postcommit #594 (See
[https://builds.apache.org/job/Tajo-trunk-postcommit/594/])
TAJO-343: Implement locate function. (KyoungBok Lee via hyunsik) (hyunsik:
https://git-wip-us.apache.org/repos/asf?p=incubator-tajo.git&a=commit&h=3c2a6343fe9056c9e520442b744ba924704fc3dd)
* CHANGES.txt
*
tajo-core/tajo-core-backend/src/main/java/org/apache/tajo/master/TajoMaster.java
*
tajo-core/tajo-core-backend/src/test/java/org/apache/tajo/engine/function/TestStringOperatorsAndFunctions.java
*
tajo-core/tajo-core-backend/src/main/java/org/apache/tajo/engine/function/string/Locate.java
> Implement locate function
> -------------------------
>
> Key: TAJO-343
> URL: https://issues.apache.org/jira/browse/TAJO-343
> Project: Tajo
> Issue Type: New Feature
> Components: operator/function/udf
> Reporter: Hyunsik Choi
> Assignee: KyoungBok Lee
> Priority: Minor
> Fix For: 0.8-incubating
>
> Attachments: TAJO-343.2.patch, TAJO-343.patch
>
>
> h3. Function definition
> {code}
> int4 locate(string text, substr text, [, pos])
> {code}
> h3. Description
> Returns the position of the first occurance of substr in str after position
> pos
> * The result is one-based index.
> * If string or substr is null, the result should be null.
> * *pos* is one-based index.
> * *pos* cannot be a negative integer.
> * If 0 is given to *pos*, the function considers that pos is 1.
> * If there is no pos, the function considers that pos is 1.
> * If there is no matched substring, the result should be 0.
> h3. Example
> {code}
> SELECT locate('foobarbar', 'bar',5);
> -> 7
> {code}
--
This message was sent by Atlassian JIRA
(v6.1#6144)