You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@asterixdb.apache.org by "Yingyi Bu (JIRA)" <ji...@apache.org> on 2016/01/18 21:42:39 UTC

[jira] [Commented] (ASTERIXDB-1259) Function calls with returned values in Sqlpp return unexpected exception

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

Yingyi Bu commented on ASTERIXDB-1259:
--------------------------------------

In the current version of SQL++, double quotes are used for delimited identifiers (this is the same as in standard SQL) and only single quotes are used for string literals. But this is going to be changed-- we probably will use backticks (``) for delimited identifiers.

But this is going to be changed.

Therefore, the following query will return the correct result:

drop database test if exists;
create database test;
use test;
create function printName(){ 
'AsterixDB Shared nothing parallel BDMS' 
}
select element printName();

Besides, there is a common issue in AQL parser and SQL++ for UDFs that
the wrap parens couldn't be in the same line of the function body.


> Function calls with returned values in Sqlpp return unexpected exception
> ------------------------------------------------------------------------
>
>                 Key: ASTERIXDB-1259
>                 URL: https://issues.apache.org/jira/browse/ASTERIXDB-1259
>             Project: Apache AsterixDB
>          Issue Type: Bug
>          Components: AsterixDB
>            Reporter: Murtadha Hubail
>            Assignee: Yingyi Bu
>
> If you execute the following queries, instead of printing the returned function result, you will get an exception:
> drop database test if exists;
> create database test;
> use test;
> create function printName()
> {
> "AsterixDB Shared nothing parallel BDMS"
> }
> use test;
> select element printName();



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