The next query returns strange result.
EXECUTE DIRECT ON (datanode1) $$SELECT relkind FROM pg_class GROUP BY relname, relkind$$;
It should return like Table A, but it returns like Table B.
relkind --------- i r v t (4 rows)
relkind --------- h \x18 ` 8 \x10 X 0 x \x08 P ( p H
And next queries return the right results.
# execute direct on (datanode1) $$select relkind from pg_class group by relkind$$; # execute direct on (datanode1) $$select relname, relkind from pg_class group by relname, relkind$$;
It seems that this problem is produced when select target does not contain all of the columns listed in the GROUP BY clause.
Log in to post a comment.