CSV File not comma seperated

Hi,
When I try to download Statistics the file is not formatted as a csv file, there is no separation.

If I open the file in Excel each record is on its own row but not separated by cell.

Is this something that needs configuring?

Thanks
Tony

You need to add or change this line in your config.php file. phplist will then use comma for the field separator in export files

define("EXPORT_EXCEL",1);

Hey, the csv is tab separated - when you open the file in excel you can select tab as the deliminator. I think there is a wizard to help them. It is set like this (rather than comma) to allow free text attributes with commas in them.

Hi,

Thank you both, I have gone with Anna’s option and it worked a treat :slight_smile: nice and easy

Cheers
Tony

1 Like

Hi Duncan,

Its not working with your suggestion. The file is still Tab Separated and not Comma Separated. Can you please help me more. I don’t want Tab Separated.

I changed this also but not working

$export_mimetype = ‘application/vnd.ms-excel’;

@boxygen Ensure that you do not have two define statements because only the first one will be used.

Ok Now I found that your solution is working perfectly for Export Subscribers Section But it is not working for Export View Stats.

I have attached the screen shots for both

View Stats

Export Subscibers

Please suggest

@boxygen That’s a problem with phplist being inconsistent. You can raise an issue on the bug tracking system https://mantis.phplist.org/view_all_bug_page.php

Alternativel you can use the Campaign Statistics plugin, that also has an export function which might work with excel. Follow the Find plugins link on the Manage Plugins page.

I got this error while installing the plugin

Dependency checkPlugin can not be enabled.
Failure on system requirement Common Plugin v3.0.3 or later installed

Have you installed the CommonPlugin as required by many of Duncan’s plugins?
https://resources.phplist.com/plugin/common

Thanks its working now

Thanks Druncan now CSV is working