This generates the error message below: ConvertToPdf1 failed (0.315s):You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'function convertToMarkdown(Letter03) { const headers = [Object.keys(Letter03[0])' at line 1
The MySql File "Letter03" is shown in the attached screen capture.
I am routing out to PHP Code that uses FPDF code and this works well except it produces a .csv file that has to manually converted to a .xlsx file so it will hold together after emailing
Retool has an app for exporting MySQL to an .xlsx which gives a stable file but the content does not extend to adjacent cells even when the adjacent cell is empty. So the headers are not good.
Generally we will use option 1) and get the user to "Save As" an Excel file (.xlsx).
I will mark this as a solution so we can close it off.