Query Running Indefinitely in Retool Application

Two things you can do here.

Set the timeout to be in a reasonable amount of time to run the query. If it can't do it in that time, it will stop.

Second, you need to just set the FROM part to be the name of your table in the Retool db. Usually naming your table like you have it "CSVData" isn't going to work.

Try renaming your table to csvdata, and then do the following statement in your query1:
SELECT *
FROM csvdata

This should work.