UDF script with EMITS(...) requires parameters
Details
| Detail name | Value |
|---|---|
| Changelog Number | 7278 |
| Type | Bug |
| Status | Resolved |
| Affected Versions | Exasol 6.1.0 |
| Fix Versions | Exasol 6.1.1 |
| Resolution Date | 2019-01-04 |
Background
In Exasol 6.1.0 UDF scripts with dynamic parameters (i.e., EMITS(...)) require
at least one input parameter. Without parameter Exasol 6.1.0 throws a syntax error.
Example:
create or replace lua scalar script script() emits (...) as function run(ctx) ctx.emit(5) end / select script() emits (i double);
Workaround
Add a dummy input parameter.
Example:
create or replace lua scalar script script(a int) emits (...) as function run(ctx) ctx.emit(5) end / select script(NULL) emits (i double);