Misleading router executor error with complex subqueries
Problem
Hitting cannot handle complex subqueries when the router executor is disabled error when the router executor is enabled
Steps to reproduce:
CREATE TABLE table_1 (id int, t1 int);
SELECT create_distributed_table('table_1', 'id');
CREATE TABLE table_2 (id serial, t2 int);
SELECT create_distributed_table('table_2', 'id');
-- insert-select query with complex subquery errors out
WITH top10 AS ( SELECT id FROM table_1 WHERE t1 IS NOT NULL ORDER BY t1 LIMIT 10 )
INSERT INTO table_2 (t2) SELECT * FROM top10;
ERROR: cannot handle complex subqueries when the router executor is disabled
-- however router executor is enabled
SHOW citus.enable_router_execution;
citus.enable_router_execution
-------------------------------
on
(1 row)
This is even part of our tests right now. For reference https://github.com/citusdata/citus/pull/4914/files#r642292926
What would be steps to debug real issue with this ? My issue was closed but no solution is given/ no alternative and no root cause.
Hi @CamiloHerreraDR This seems to be a mistake on my part. Let me look further into both these issues which I might have incorrectly marked as duplicates, I will update this comment.
Edit: I reopened the other issue for further investigation. Apologies for my confusion.
Fixed by #6059