Documentation
CSV ZIP Export
Require: Symcon >= 7.0
The module exports the logged or aggregated values of several variables as CSV files. The export can be downloaded directly or sent cyclically by mail and/or via SFTP, FTP or FTPS.
Features
- Export of the raw data or the aggregated values of several variables
- One CSV file per variable or a common CSV file with one column per variable
- Export as a ZIP archive or as a single CSV file
- Freely selectable period and aggregation level
- Comma or dot as decimal separator
- Cyclic sending of the last interval (hourly, daily, weekly, monthly or yearly) by mail and/or via SFTP, FTP or FTPS
- Selection of a variable by its ident, if the module SyncMySQL is installed
Requirements
- Symcon version 7.0 or later
- The variables to export are logged in the Archive Control
- For sending by mail a configured SMTP instance
- For sending as a file a server with SFTP, FTP or FTPS, e.g. a NAS
Installation
- Install the module "CSVZipExport" via the Module Store.
- The source code is available on GitHub.
Setting up the instances in Symcon
- Under "Add Instance", the module "CSV-Zip-Export" can be found using the quick filter.
- More information about adding instances in the Instances documentation
Configuration page
| Name | Description |
|---|---|
| Export Options | "Single File per Variable" exports each variable into its own CSV file, the files are combined in a ZIP archive. "Single File with multiple Variables" exports all variables as columns into one CSV file. "MySQL" exports a logged variable that is selected by its ident. This option is only available if the module SyncMySQL is installed |
| Selected Variables | [Export options "Single File per Variable" and "Single File with multiple Variables"] List of the variables to export. A user defined name replaces the name of the variable in the column header or in the file name |
| Filter | [Export option "MySQL"] Filters the logged variables by ident or name. "Apply Filter" applies the filter |
| Logged Variables | [Export option "MySQL"] Selection of the variable to export, shown with ident and name |
| Create ZIP File | Puts the CSV file into a ZIP archive. Only selectable for "Single File with multiple Variables", the other export options always create a ZIP archive |
| Decimal Separator | Comma or dot |
| Aggregation Start | Start of the period for "Download Export Now" |
| Aggregation End | End of the period for "Download Export Now" |
| Aggregation Stage | Raw data or an aggregation level from 1-Minute to Yearly. Applies to the download and the cyclic sending |
| Download Export Now | Exports the selected period and downloads the file. The file is deleted after one hour |
| Cyclic sending | |
| Enable cyclic sending | Sends the export regularly with the selected methods |
| Interval | Hourly, Daily, Weekly, Monthly or Yearly. The last complete interval is sent: for "Daily" the previous day, for "Weekly" the previous week on Mondays, for "Monthly" the previous month on the 1st and for "Yearly" the previous year on January 1st |
| Time | Time of the sending. For "Hourly" the export is sent every hour at the selected minute |
| Send per Mail | Sends the export by mail during the cyclic sending |
| SMTP-Instance | SMTP instance used to send the mail |
| Send Mail Now | Sends the last interval by mail immediately, even if the cyclic sending is disabled |
| FTP, FTPS, SFTP | |
| Send per SFTP/FTP/FTPS | Uploads the export to a server during the cyclic sending |
| Connection Type | SFTP, FTP or FTPS (explicit FTP over TLS). FTP and FTPS use the passive mode |
| Host | Host name or IP address of the server |
| Port | Port of the server. When the connection type is changed, the default port is set (21 for FTP and FTPS, 22 for SFTP), unless another port is entered |
| Username | Username on the server |
| Password | Password of the user |
| Target Directory | Directory the file is uploaded to. "Select Directory" shows the directories of the server for selection |
| Test Connection | Checks the saved connection data |
| Send File now | Uploads the last interval immediately, even if the cyclic sending is disabled |
Status variables
The module does not create any status variables.
Examples
The exported file is named "InstanceID_InstanceName.zip" or "InstanceID_InstanceName.csv". In the ZIP archive the CSV file of a variable is named "VariableID_Name.csv".
With the export option "Single File per Variable" each CSV file contains the lines "Timestamp;Value" without a header, sorted descending by the timestamp.
With the export option "Single File with multiple Variables" the CSV file has a header and one column per variable. If a variable has no value at a timestamp, the cell stays empty:
Date;Humidity;Temperature
01.10.2026 03:30:00;50;
01.10.2026 03:00:00;;22
01.10.2026 02:00:00;45,5;21,5
Troubleshooting
If the cyclic sending fails, it is retried in the next interval. More information about an error is shown in the debug of the instance.
| Status | Description |
|---|---|
| 201 | No valid variable is selected: The list is empty or a selected variable does not exist anymore |
| 202 | No valid SMTP-Instance selected: The selected instance is not an SMTP instance |
| 203 | The selected SMTP-Instance doesn't exist |
| 204 | Cyclic sending is active, but no method is selected |
| 205 | Can not connect to the server via SFTP/FTP/FTPS: No host is entered, the server cannot be reached or the username or password is not correct |
| 206 | The target directory does not exist |
Functions
| Function | Description |
|---|---|
| CSV_DeleteZip | Deletes the last exported file |
| CSV_Export | Exports a single variable into a ZIP archive |
| CSV_ExportVariables | Exports the selected variables according to the export option |
| CSV_SendCyclic | Sends the last interval by mail and/or via SFTP, FTP or FTPS |
| CSV_SendMail | Sends the last interval by mail |