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

Support EXPLAIN command #86

Open
bonesmoses opened this issue Mar 12, 2015 · 1 comment
Open

Support EXPLAIN command #86

bonesmoses opened this issue Mar 12, 2015 · 1 comment
Labels

Comments

@bonesmoses
Copy link

Currently when an EXPLAIN is applied to a query, the following output is produced:

ERROR:  EXPLAIN statements on distributed tables are unsupported

This makes it effectively impossible to troubleshoot queries on tables using pg_shard. Even something as simple as executing the EXPLAIN on candidate worker nodes and combining the results would be sufficient as a replacement for this error.

@jasonmp85 jasonmp85 changed the title Support EXPLAIN output Support EXPLAIN command Mar 13, 2015
@jasonmp85
Copy link
Collaborator

As you've already discovered, enabling auto_explain on worker nodes is one workaround, but that's not very proactive.

Which shards would the query run on? How much data came from each candidate shard?

I agree that a "just ask a shard" approach is a nice first pass, but as you've noted, more advanced capabilities are possible if we keep statistics about the shards. CitusDB does this to help plan distributed joins (especially important is just the shard size), and I think pg_shard could benefit from a bit of that as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants