Issue 123190 - CSV import: sticky "from row" leads to truncated or empty imports
Summary: CSV import: sticky "from row" leads to truncated or empty imports
Status: CONFIRMED
Alias: None
Product: Calc
Classification: Application
Component: open-import (show other issues)
Version: 4.0.0
Hardware: All All
: P3 Normal (vote)
Target Milestone: ---
Assignee: AOO issues mailing list
QA Contact:
URL:
Keywords: usability
Depends on:
Blocks:
 
Reported: 2013-09-05 14:49 UTC by tim
Modified: 2024-01-02 17:34 UTC (History)
5 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: 4.2.0-dev
Developer Difficulty: Simple


Attachments
Screenshot with explanation (52.83 KB, application/pdf)
2013-09-09 14:26 UTC, tim
no flags Details

Note You need to log in before you can comment on or make changes to this issue.
Description tim 2013-09-05 14:49:50 UTC
The "From Row" option should reset to zero or be highlighted/pop up a query to the user if greater than zero. I was unable to get data into OO Calc from CSV files after changing the value to "2000" once. I could not figure out why all my imports were empty. (I was lucky, because if I had done "from row 5" I would have been losing data and be unaware it was happening.)
Comment 1 Edwin Sharp 2013-09-08 07:13:57 UTC
Please attach CSV file.
Comment 2 tim 2013-09-09 14:26:35 UTC
Created attachment 81494 [details]
Screenshot with explanation

I was asked to attach a sample CSV file, but the defect would be true with ANY CSV file. To reproduce:
1) Import a CSV file and set all your import setting, INCLUDING making "From row:" greater than 1.
2) Open a second, different CSV file. Setting are matched to your last import, including "From row:" line.

This is easily overlooked and can cause unexpected results.

I suggest one of the following solutions
A) a warning if >1 to alert user
B) an auto-reset to 1
C) only make "sticky" for the same exact filename. 
D) A color highlight in GUI interface for this area if greater than 1

Method A, the warning, is my preferred solution. (I guess you could include a checkbox asking to suppress the warning on future imports for people who always want to skip row 1, for example.)
Comment 3 tim 2013-09-09 14:27:16 UTC
See screenshot and explanation.
Comment 4 Edwin Sharp 2013-09-09 18:57:32 UTC
Thank you for the explanation.

From row field having memory even after closing AOO is indeed a bad thing.
Comment 5 damjan 2023-12-30 17:46:15 UTC
> A) a warning if >1 to alert user

Might break UI automation, and interfere with users' workflow.

> B) an auto-reset to 1

This is probably the easiest to implement. The code appears to be in load_Separators() and save_Separators() in file main/sc/source/ui/dbgui/scuiasciiopt.cxx.

> C) only make "sticky" for the same exact filename. 

Hard to implement, and has privacy/security implications by storing a history of CSV files you opened...

> D) A color highlight in GUI interface for this area if greater than 1

That's an interesting option.

> Method A, the warning, is my preferred solution. (I guess you could include
> a checkbox asking to suppress the warning on future imports for people who
> always want to skip row 1, for example.)

My preferred ways would be B or D. What do others think?
Comment 6 Matthias Seidel 2024-01-02 17:34:11 UTC
For the moment I would prefer B.