Disallow duplicated parameter names in UDFs
Details
| Detail name | Value |
|---|---|
| Changelog Number | 12820 |
| Type | Bug |
| Status | Resolved |
| Affected Versions | Exasol 7.0.0, Exasol 7.1.0, Exasol 8.0.0 |
| Fix Versions | Exasol 8.7.0 |
| Resolution Date | 2022-11-01 |
Description
Previously UDFs allowed duplicate parameter names.
The usage of those duplicate parameters was undefined.
Example:
It is not defined whether the first or the second parameter is returned.
CREATE OR REPLACE PYTHON3 SCALAR SCRIPT test.dup(p1 INT, p1 INT)
RETURNS int AS
def run(ctx):
return ctx.p1
/
Workaround
There is no workaround
Fix
The creation of such scripts returns the error "duplicate parameter name: p1".
Changed behavior
The creation of UFDs with duplicated parameter names now returns the error "duplicate parameter name: p1"