Dataset Refresh Failed Error Code "Subquery Error"

I revised the dataset in QuickSight to add 2 additional columns. It was successfully published and saved in dataset and has a successful load job completion, but when I fully imported data in Spice and refresh whole dataset, it’s shown failed because 'Amazon Invalid operation: This type of correlated subquery pattern is not supported due to internal error;

Hi @ShangLi - Welcome to AWS QuickSight Community and thanks for posting the question. I assume you have created a custom sql and it is not supported by SPICE. To get more details, can you share the sql or share the screenshot ( ensure there is no PII or PCI info are shared). This will help to understand the issue and guide you right solution.

In parallel, you can raise a ticket to AWS Customer support team so that they can see your issue via screen share and advise you. To raise a ticket, please follow the details in the link - Creating support cases and case management - AWS Support

Regards - Sanjeeb

1 Like

Hi - yes I did use custom sql to build dataset, but it was successfully refreshed before without error. I only added one column in the final table and didn’t add any additional query. Below is the sql screenshot.

And the issue happened when I added desired_inventory_level

Hi @ShangLi - Is it possible to take the sql and run in DB level directly as I am not sure from which table the column desired_inventory_level is coming. From SQL it looks correct to me as you already put the group by condition. Take the subquery and run it in DB to see whether any issues are there or not. If not, then took the whole sql and run it in DB before using it as custom sql in QuickSight.

Regards - Sanjeeb

1 Like

Hi - I already ran it in DB and it ran sucessfully without error. It was successfully published and saved in QuickSight, but when I refershed it, it failed.

1 Like

Hi @ShangLi - Do we have any error screenshot or any other details. Since it is very difficult to analyze the SPICE errors in the community, i will request you to raise a ticket to AWS Customer support team so that they can analyze the issue by screen share and also check the error from QuickSight side. To raise a ticket, please follow the link - Creating support cases and case management - AWS Support

If you do not have access to raise a ticket, request your aws admin team to submit the case on behalf of you.

Regards - Sanjeeb

1 Like