SQL query, preview returns data but "Run" returns "404"

I'm using a MySQL connection through SSH.

The connection went OK.
The query, clicking "Preview" returns the supposed data.
The query, when clicking "Run" returns

  • statusCode:404
  • error:"Not Found"
  • message:"Unable to retrieve information about the query "eupago""
  • data:null

Does anyone have a clue why this might be happening ?

Thanks.!

This is an especially weird scenario. Both the previewed query and the query that is actually run should be the same in this state, the only difference that comes to mind is that the one which is run is saved to the app and the previewed query could potentially have an unsaved state.This could be from a fringe caching scenario, would you mind testing after fully clearing your browser cache? If you are still seeing the same thing after, we will need to take a closer look. Could you write in through the in-app chat in the bottom right of the editor to confirm ownership and let us know it is OK with you if we open up the app from our end?

We’ll post back in this thread afterwards with any findings

Hi Alex,

Ok. Will start a chat in-app. See you people there.

1 Like

We resolved this over chat, but I’m posting our solution here as well for the rest of the community :slightly_smiling_face:This issue was a result of the 2 week free trial of Retool ending. After the trial expires, you can open your apps in the editor, but you need to select a plan before you can save changes to your queries. While we can preview unsaved changes, we cannot save and run the query changes until a plan is selected.

If you see the trial expired banner at the top of your screen, please select a plan to continue using and editing your apps. Even if you opt for the free plan, you’ll need to have an admin in your organization navigate to the billing page and select the plan you want to use.

1 Like

Hi Tess, we are facing the same issue again.

Currently we are using self-hosted retool version 3.2.3 and we have subscribed Business plan.

Hi @Yingqi_Wang

Thanks for letting us know :disappointed: I haven't heard this feedback from others recently, so I have some follow up questions --

Do any queries to your resource work? Did the erroring out query previously work on this Retool instance?

What happens when you create a new query to this resource (something simple like return 1 row)?

If you go to the resource page and click "Test connection," do you see a successful response?

Additionally, do other database or API resources work as expected, if you have any?

To rule out any billing issues, can you check the billing page (Settings->Billing) to see what plan level is selected? It's potentially possible that the instance isn't connecting properly with your billing info. It would also be helpful if you could DM me the email used for billing.

Hi @Tess ,

Thanks for your reply and please check below in-line answers to your question.

Do any queries to your resource work? Did the erroring out query previously work on this Retool instance?
-- We have only one mysql database, and we created the same DB resource on both cloud Retool and self-host one. This data source is working perfectly fine in a cloud retool App, but when we are trying to export the app from cloud and import to self-hosted instance via JSON, the app not working as expected.

What happens when you create a new query to this resource (something simple like return 1 row)?
-- If we create a new app on self-hosted Retool and build a new query to the data source, it return expected result.

If you go to the resource page and click "Test connection," do you see a successful response?
-- As checked in resource editing page, test connection successful.

Additionally, do other database or API resources work as expected, if you have any?
-- We haven't tested that, since we are only working with this DB (resource)

To rule out any billing issues, can you check the billing page (Settings->Billing) to see what plan level is selected?
-- my current plan is shown as "Business"

Eventually this problem solved by Retool support:

Root cause
The JSON file we are attempting to import is exceeding the maximum allowed client body size as configured on our self-hosted instance, likely through a reverse-proxy like NGINX.

Solution
Using NGINX, we update [client_max_body_size] in .conf file to a value of at least 5m