asterixdb-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Yingyi Bu (JIRA)" <j...@apache.org>
Subject [jira] [Comment Edited] (ASTERIXDB-1259) Function calls with returned values in Sqlpp return unexpected exception
Date Mon, 18 Jan 2016 20:42:39 GMT

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

Yingyi Bu edited comment on ASTERIXDB-1259 at 1/18/16 8:42 PM:
---------------------------------------------------------------

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:

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

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.



was (Author: buyingyi):
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)

Mime
View raw message