Daniel - I have a SQL statement that will return results when run directly against the DB (in phpMyAdmin), but when I use your plug-in, nothing is downloaded. This is the only thing on the template, so it’s something in your plug-in it would seem? I can’t figure it out - I’ve been looking at the plug-in and I can’t see any reason this wouldn’t work:
{exp:csvee query="SELECT
company_uid,
FROM_UNIXTIME(entry_date, '%m/%d/%Y') AS `date`,
company,
last_name,
first_name,
title,
address,
address_2,
city,
state,
county,
zip,
phone,
fax,
email,
url,
contact_control,
business_description,
employees,
category,
member_discount,
options,
membership_level,
REPLACE(donation, 'Other:', '') AS donation,
donation_amount,
'CC' AS `payment type`,
approval_num,
tags,
member_to_member_communication,
password,
subscription_id AS `notes`
FROM exp_freeform_entries
WHERE form_name = 'update_info_form'
ORDER BY entry_date
DESC"
filename="update_submissions.csv"}
I have two other export templates that use that exact same code and just changes the “WHERE” clause, and they both work as well. Any thoughts? Could there be something in the results themselves that could be somehow tripping up the generation of the CSV?
Thanks…