What you can do then is create a page called example.xls put PHP code into it that will dynamically create the file.
An excel file is just a tab delimited file at it's most basic and the rows are delimited by carriage returns.
So being cautious of extra white space write a loop that will set up the first row with column headers if you want them. DO NOT name the first column just id if you want id use, store_id or something as Microsoft will think it is a different file if it starts with id for some reason.
So the code should look something like You will have to PHP this if that is what you are using:
header_array = ['column1', 'column2', 'column3', 'column4']
data = sql_execute('select column1, column2, column3, column4 from table where condition = condition')
for value in header_array:
for value in data:
So what you will want to do is give the user a link or a form to submit and make this page the landing page.
Their browser will see the .xls file extension and ask the user want they want to do with the file. The file will be written and sent to the browser without a copy having ever really been made on your server.
I hope this will work for you.