When I export a csv file from my database and I want to loop over the records, then KR does one extra loop at the end.
Basically many database systems when exporting use the csv format with an empty line at the end.
KR cannot handle this and runs one extra time for the empty line.
This blocks me in further automating.
I now have to run KR line per line in the csv manually.
Can’t you edit the file?
An external process could be used to trim extraneous whitespace.
Same question as Russ, can’t you manually remove the last line from the file?
Yes, but isn’t that precisely why we use KR to automate work?
Now I have to manually open the csv file, remove the last line, save it, close it.
I need to run this multiple times per day, manually, defeating the enitre purpose of automation…
Okay I got your point, I thought you were doing this:
which is a rather extreme solution for the problem instead of just deleting the final line in the CSV file.
But thank you for your report, we’ll fix it and inform you when there’s something new.
@koen.rens
I added empty lines to my data file but cannot reproduce this issue. Can you help provide a sample data file where this problem is observed? Do you mean an empty line or a line of white spaces and commas combined?
Need to use text or notepad++ to open, manually delete the last line
@1968693027
Can you provide a sample CSV file with this problem? I tried this on my side and I haven’t been able to reproduce it yet.
When using excel to create a new file, and change the file format to csv, then open it with Notepad or notepad++ and you will find that the last line is a blank line. When the data is driven, the last line will be read, resulting in an error, in order to avoid Error, I deleted the last line manually