Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

function not_uniques(bigint) returns error when called #6813

Closed
monetdb-team opened this issue Nov 30, 2020 · 0 comments
Closed

function not_uniques(bigint) returns error when called #6813

monetdb-team opened this issue Nov 30, 2020 · 0 comments
Labels
bug Something isn't working normal SQL

Comments

@monetdb-team
Copy link

Date: 2020-01-29 16:49:03 +0100
From: Martin van Dinther <<martin.van.dinther>>
To: SQL devs <>
Version: 11.35.9 (Nov2019-SP1)
CC: @PedroTadim

Last updated: 2020-06-03 16:58:52 +0200

Comment 27530

Date: 2020-01-29 16:49:03 +0100
From: Martin van Dinther <<martin.van.dinther>>

User-Agent: Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:70.0) Gecko/20100101 Firefox/70.0
Build Identifier:

select not_uniques(1);
returns: Error: Implementation for function sql.not_uniques not found.
SQLState: HY005

The function is listed in sys.functions as system function twice with signatures:
not_uniques(bigint) returns oid
not_uniques(oid) returns oid

Either add implementation for the function or remove it from sys.functions and sys.args

Reproducible: Always

Steps to Reproduce:

select not_uniques(1);
select not_uniques(cast (1 as oid));
select * from sys.functions where name = 'not_uniques';
select * from sys.args a where func_id in (select id from sys.functions where name = 'not_uniques');

Actual Results:

sql>select not_uniques(1);
Implementation for function sql.not_uniques not found
sql>select not_uniques(cast (1 as oid));
Implementation for function sql.not_uniques not found
sql>select * from sys.functions where name = 'not_uniques';
+------+-------------+-------------+------+----------+------+-------------+--------+--------+-----------+--------+
| id | name | func | mod | language | type | side_effect | varres | vararg | schema_id | system |
+======+=============+=============+======+==========+======+=============+========+========+===========+========+
| 64 | not_uniques | not_uniques | sql | 0 | 1 | false | false | false | 2000 | true |
| 65 | not_uniques | not_uniques | sql | 0 | 1 | false | false | false | 2000 | true |
+------+-------------+-------------+------+----------+------+-------------+--------+--------+-----------+--------+
2 tuples
sql>select * from sys.args a where func_id in (select id from sys.functions where name = 'not_uniques');
+------+---------+-------+--------+-------------+------------+-------+--------+
| id | func_id | name | type | type_digits | type_scale | inout | number |
+======+=========+=======+========+=============+============+=======+========+
| 2257 | 64 | res_0 | oid | 63 | 0 | 0 | 0 |
| 2258 | 64 | arg_1 | bigint | 64 | 0 | 1 | 1 |
| 2259 | 65 | res_0 | oid | 63 | 0 | 0 | 0 |
| 2260 | 65 | arg_1 | oid | 63 | 0 | 1 | 1 |
+------+---------+-------+--------+-------------+------------+-------+--------+
4 tuples

Expected Results:

No 'Implementation for function sql.not_uniques not found' error.

Comment 27532

Date: 2020-01-30 10:16:21 +0100
From: MonetDB Mercurial Repository <>

Changeset 274dd36dafe6 made by Pedro Ferreira pedro.ferreira@monetdbsolutions.com in the MonetDB repo, refers to this bug.

For complete details, see https//devmonetdborg/hg/MonetDB?cmd=changeset;node=274dd36dafe6

Changeset description:

Find backend implementation for SQL basic functions at server startup. Removed 'not_uniques' and 'in' functions as they don't have a backend implementation. This fixes bug #6813
@monetdb-team monetdb-team added bug Something isn't working normal SQL labels Nov 30, 2020
@sjoerdmullender sjoerdmullender added this to the Ancient Release milestone Feb 7, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working normal SQL
Projects
None yet
Development

No branches or pull requests

2 participants