AWS Redshift failed to make a valid plan when trying to run a complicated query

0 votes

I'm running a complicated query against a Redshift cluster in which there are 4 tables used with some of them have billions of rows, and I get the following error:

failed to make a valid plan

If I limit the data, the query will run successfully.

Oct 3, 2018 in AWS by eatcodesleeprepeat
• 4,670 points
14 views

1 answer to this question.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
0 votes
-The Original query was an Oracle query which I've made some modifications on it, and data loaded in the tables in Redshift was also exported from Oracle.

-The query has a lot of JOINs and sub queries.

With those being said, going through the sub-queries one at a time, one of them didn't return any results, and that was the cause of this error in my case.

Fixing that particular sub-query and the main query accordingly, it worked successfully.
answered Oct 3, 2018 by Priyaj
• 56,100 points

Related Questions In AWS

0 votes
1 answer

How to skip headers when reading a CSV file in S3 and creating a table in AWS Athena?

This is a known deficiency. The best ...READ MORE

answered Sep 4, 2018 in AWS by Archana
• 3,770 points
471 views
0 votes
1 answer

How to make a subnet public using AWS Console?

To make a subnet public you need ...READ MORE

answered Feb 11 in AWS by Priyaj
• 56,100 points
22 views
0 votes
1 answer
0 votes
1 answer

Error in Adding LIMIT fixes “Invalid digit, Value N” in Amazon Redshift.

This could be expressed simply as: SELECT TOP ...READ MORE

answered Sep 4, 2018 in AWS by Priyaj
• 56,100 points
915 views
0 votes
1 answer

Scaling in Amazon Redshift

The existing data warehouse cluster remains available ...READ MORE

answered Sep 27, 2018 in AWS by Archana
• 3,770 points
15 views
0 votes
1 answer

Single-Node Cluster & Multiple-Node Cluster

In the single-node cluster, you have a ...READ MORE

answered Sep 27, 2018 in AWS by Archana
• 3,770 points
21 views
0 votes
1 answer

© 2018 Brain4ce Education Solutions Pvt. Ltd. All rights Reserved.
"PMP®","PMI®", "PMI-ACP®" and "PMBOK®" are registered marks of the Project Management Institute, Inc. MongoDB®, Mongo and the leaf logo are the registered trademarks of MongoDB, Inc.