Vertica-Extension-Packages
Vertica-Extension-Packages copied to clipboard
compatlib_function - ConnectBy supports only an integer input. It does not work when the parent-child relationship is established as a STRING / VARCHAR.
compatlib_function - ConnectBy supports only an integer input. It does not work when the parent-child relationship is established as a STRING / VARCHAR.
Confirmed connect_by_path accepts only INTEGER values for parent ID and child ID. If it was run with the following data, the error happened.
=> CREATE TABLE company (id VARCHAR, supervisor_id VARCHAR, name VARCHAR(20));
=> INSERT INTO company VALUES ('1', null, 'Patrick');
=> INSERT INTO company VALUES ('2', '1', 'Jim');
=> INSERT INTO company VALUES ('3', '1', 'Sandy');
=> INSERT INTO company VALUES ('4', '3', 'Brian');
=> INSERT INTO company VALUES ('5', '3', 'Otto');
=> COMMIT;
=> SELECT connect_by_path(supervisor_id, id, name, ' >> ') OVER () FROM company;
vsql:connect_by_path.sql:21: ERROR 3457: Function connect_by_path(varchar, varchar, varchar, unknown) does not exist, or permission is denied for connect_by_path(varchar, varchar, varchar, unknown)
HINT: No function matches the given name and argument types. You may need to add explicit type casts
I will work on this issue.