Bug 17590 - Exporting reports as CSV with 'delimiter' SysPref set to 'tabulation' creates files with 't' as separator
Summary: Exporting reports as CSV with 'delimiter' SysPref set to 'tabulation' creates...
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Reports (show other bugs)
Version: Main
Hardware: All All
: P5 - low normal
Assignee: Nick Clemens (kidclamp)
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-11-08 17:28 UTC by Nick Clemens (kidclamp)
Modified: 2021-05-12 10:39 UTC (History)
5 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Trivial patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:


Attachments
Bug 17590 - Exporting reports as CSV with 'delimiter' SysPref set to 'tabulation' creates files with 't' as separator (1.26 KB, patch)
2016-11-08 17:31 UTC, Nick Clemens (kidclamp)
Details | Diff | Splinter Review
[SIGNED-OFF] Bug 17590 - Exporting reports as CSV with 'delimiter' SysPref set to 'tabulation' creates files with 't' as separator (1.35 KB, patch)
2016-11-09 22:28 UTC, Bernardo Gonzalez Kriegel
Details | Diff | Splinter Review
Bug 17590 - Exporting reports as CSV with 'delimiter' SysPref set to 'tabulation' creates files with 't' as separator (1.40 KB, patch)
2016-11-18 09:59 UTC, Jonathan Druart
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Nick Clemens (kidclamp) 2016-11-08 17:28:55 UTC
We need to translate 'tabulation' to "\t" before creating our file with Text::CSV
Comment 1 Nick Clemens (kidclamp) 2016-11-08 17:31:35 UTC
Created attachment 57342 [details] [review]
Bug 17590 - Exporting reports as CSV with 'delimiter' SysPref set to 'tabulation' creates files with 't' as separator

To test:
Set 'delimiter' system preference to 'tabs'
Export a report as csv
Open the file in text editor and note fields separated by character 't'
Apply patch
Export report as CSV
Open file in text editor and note tabs are used to separate fields
Comment 2 Bernardo Gonzalez Kriegel 2016-11-09 22:28:21 UTC
Created attachment 57407 [details] [review]
[SIGNED-OFF] Bug 17590 - Exporting reports as CSV with 'delimiter' SysPref set to 'tabulation' creates files with 't' as separator

To test:
Set 'delimiter' system preference to 'tabs'
Export a report as csv
Open the file in text editor and note fields separated by character 't'
Apply patch
Export report as CSV
Open file in text editor and note tabs are used to separate fields

Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
tabs now, no errors.
Comment 3 Marcel de Rooy 2016-11-11 08:00:13 UTC
Hm I cannot recreate your problem.
Your test plan "Export your report" is far from clear.
Do I need to set some preferences to get this Export option?
Comment 4 Jonathan Druart 2016-11-18 09:59:16 UTC
Created attachment 57625 [details] [review]
Bug 17590 - Exporting reports as CSV with 'delimiter' SysPref set to 'tabulation' creates files with 't' as separator

To test:
Set 'delimiter' system preference to 'tabs'
Export a report as csv
Open the file in text editor and note fields separated by character 't'
Apply patch
Export report as CSV
Open file in text editor and note tabs are used to separate fields

Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
tabs now, no errors.

Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Comment 5 Jonathan Druart 2016-11-18 10:00:30 UTC
(In reply to Marcel de Rooy from comment #3)
> Hm I cannot recreate your problem.
> Your test plan "Export your report" is far from clear.
> Do I need to set some preferences to get this Export option?

It's the "Download" link on /reports/guided_reports.pl?reports=1&phase=Run%20this%20report
Comment 6 Jonathan Druart 2016-11-18 10:01:04 UTC
Note that it would make sense to remove the "tab separated text" entry if the pref is set to tabulation.
Comment 7 Kyle M Hall (khall) 2016-11-18 14:14:57 UTC
Pushed to master for 16.11, thanks Nick!
Comment 8 Julian Maurice 2016-11-30 13:33:06 UTC
Pushed to 3.22.x, will be in 3.22.13
Comment 9 Mason James 2016-12-14 12:14:48 UTC
Pushed to 16.05.x, for 16.05.06 release