I think that the easiest way would be to go back to the original connection to your Data Source that you made in Tableau Desktop, prior to publishing to Server. You can then convert the connection to Custom SQL, which should give you what you need
All the best
Additionally, you can find the query in the C:\Program Data\Tableau\Tableau Server\tabsvc\logs\vizqlserver\tabprotosrv.txt.
Run the extract refresh, (or wait for the schedule to run it), then open this file. You should see the SELECT statement in there.
Hi Glen, Thank you so much for your reply. The server log location is exactly what I am looking for. You rock!