Need to unpick some SQL script in Excel

Job ID: 37181318

Budget: $30 – $250 USD

We have a daily report which is pulling information from our ERP system into Excel. It's messy and the author is no longer with us.

Deliverables
I'd like to understand what tables in our ERP system the data is being pulled from, so that I can re-write the report, probably using Power BI.
Related categories: Excel SQL Excel VBA Excel Macros Power BI