Prevent empty CSV files from being created

How to tell EDT to not create a CSV file if no data matches filter criteria?

Right now, I have empty CSV files created with just the header row, which is not needed. Then I have to manually check and delete this file.

Hi Praveen

You can do this using Output to set to Multiple files for the output in v1.24.0. If there is no row with the file data, it won’t be written. See 1. from:
https://www.easydatatransform.com/easydatatransform_v1p0.html

If there was an option to not write datasets with no rows when Output is set to Single file , then you might end up with the previous output instead. Which would be worse than a CSV file with no rows, wouldn’t it? Currently Easy Data Transform never deletes files, and we don’t have any plans to change that.

If there was an option to not write datasets with no rows when Output is set to Single file , then you might end up with the previous output instead.

I don’t follow. Can you please clarify what you mean by “previous output” ? Please give a simple example to illustrate.

Lets say you have a .transform that ultimately writes output.csv, but only if it has >0 rows. You run the .transform the first time and the output has 10 rows, so output.csv is written. Then you run it again (perhaps days later) and the output has 0 rows, so output.csv is not written. You still have the output.csv written by the previous run.

Okay, thank you, I understand now.