You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues-all@impala.apache.org by "gaoxiaoqing (Jira)" <ji...@apache.org> on 2022/11/16 12:17:00 UTC
[jira] [Updated] (IMPALA-11728) Set fallback database for functions
[ https://issues.apache.org/jira/browse/IMPALA-11728?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
gaoxiaoqing updated IMPALA-11728:
---------------------------------
Description:
{code:java}
CREATE FUNCTION default.function_name([arg_type[, arg_type...])
RETURNS return_type
LOCATION 'hdfs_path_to_dot_so'
SYMBOL='symbol_name' {code}
{noformat}
use functional;
select function_name();
ERROR: AnalysisException: functional.function_name() unknown for database functional.{noformat}
The create function statement can only works on specified default database.
Add a fallback database for functions as query option. It works on all database without changing query.
{noformat}
use functional;
set db_name_with_global_udf=default;
select function_name(); // It works.{noformat}
was:
{code:java}
CREATE FUNCTION default.function_name([arg_type[, arg_type...])
RETURNS return_type
LOCATION 'hdfs_path_to_dot_so'
SYMBOL='symbol_name' {code}
{noformat}
use functional;
select function_name();
ERROR: AnalysisException: functional.function_name() unknown for database rawdata.{noformat}
The create function statement can only works on specified default database.
Add a fallback database for functions as query option. It works on all database without changing query.
{noformat}
use functional;
set db_name_with_global_udf=default;
select function_name(); // It works.{noformat}
> Set fallback database for functions
> -----------------------------------
>
> Key: IMPALA-11728
> URL: https://issues.apache.org/jira/browse/IMPALA-11728
> Project: IMPALA
> Issue Type: New Feature
> Reporter: gaoxiaoqing
> Assignee: gaoxiaoqing
> Priority: Major
>
> {code:java}
> CREATE FUNCTION default.function_name([arg_type[, arg_type...])
> RETURNS return_type
> LOCATION 'hdfs_path_to_dot_so'
> SYMBOL='symbol_name' {code}
>
> {noformat}
> use functional;
> select function_name();
> ERROR: AnalysisException: functional.function_name() unknown for database functional.{noformat}
>
> The create function statement can only works on specified default database.
> Add a fallback database for functions as query option. It works on all database without changing query.
> {noformat}
> use functional;
> set db_name_with_global_udf=default;
> select function_name(); // It works.{noformat}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-all-unsubscribe@impala.apache.org
For additional commands, e-mail: issues-all-help@impala.apache.org