You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hawq.apache.org by "Ruilong Huo (JIRA)" <ji...@apache.org> on 2016/07/05 06:59:11 UTC

[jira] [Comment Edited] (HAWQ-821) Inner function does not exist while invoking from outer function on mac osx

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

Ruilong Huo edited comment on HAWQ-821 at 7/5/16 6:58 AM:
----------------------------------------------------------

Per investigation, it is expected that:
1. The function works when optimizer is set to on, i.e., orca.
2. The function raise error "function inner(integer) does not exist" when optimizer is set to off, i.e., planner.

So, resolve this issue as "Not A Bug".


was (Author: huor):
Per investigation, it is expected that:
1. The function works when optimizer is set to on, i.e., orca.
2. The function raise error "function inner(integer) does not exist" when optimizer is set to off, i.e., planner.

So, resolve this issue as no fix needed.

> Inner function does not exist while invoking from outer function on mac osx
> ---------------------------------------------------------------------------
>
>                 Key: HAWQ-821
>                 URL: https://issues.apache.org/jira/browse/HAWQ-821
>             Project: Apache HAWQ
>          Issue Type: Bug
>          Components: Query Execution
>    Affects Versions: 2.0.0
>            Reporter: Ruilong Huo
>            Assignee: Ruilong Huo
>             Fix For: 2.0.0
>
>
> In suite of function basics in new feature test framework, inner function does not exist while invoking from outer function on mac osx. It works on rhel 6.x.
>  
> {noformat}
> -- 1. prepare schema and data
> DROP TABLE IF EXISTS foo;
> CREATE TABLE foo AS SELECT * FROM generate_series(1, 10) x;
> CREATE FUNCTION inner(int) RETURNS INTEGER AS 'SELECT 1' LANGUAGE SQL IMMUTABLE;
> CREATE FUNCTION outer(x INT) RETURNS INT AS $$
> BEGIN
> RETURN inner(x);
> END
> $$ LANGUAGE PLPGSQL;
> -- 2. run query on mac errors out with inner function does not exist
> SELECT outer(0);
>  outer
> -------
>      1
> (1 row)
> SELECT outer(0) FROM foo;
> ERROR:  function inner(integer) does not exist  (seg2 localhost:40000 pid=30499)
> DETAIL:  PL/pgSQL function "outer" line 2 at return
> -- 3. run query on rhel 6.x succeed
> SELECT outer(0);
>  outer
> -------
>      1
> (1 row)
> SELECT outer(0) FROM foo;
>  outer
> -------
>      1
>      1
>      1
>      1
>      1
>      1
>      1
>      1
>      1
>      1
> (10 rows)
> -- 4. clean up
> DROP FUNCTION outer(int)
> DROP FUNCTION inner(int);
> {noformat}



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