Apache OpenOffice (AOO) Bugzilla – Issue 50825
Datapilot: Pagefileds and filter option overwrite source area
Last modified: 2013-08-07 15:14:30 UTC
open attached document start datapilot Area -> Column Salesman -> Row 2000 -> Data click more disable 'Add filter' OK restart dataplilot case 1: check 'Add filter' case 2: drop Products -> Page OK -> line 21 get's overwritten
Created attachment 27238 [details] use this document to reproduce
It's intended (and specified) that way: "If the number of page fields in an existing DataPilot table is changed, the table's start position on the sheet is moved up or down, so the area with the column/row fields and data (with the thick border) starts at the same position." (http://specs.openoffice.org/calc/compatibility/pagefields.sxw).
Sorry, then the specification got to be changed because after a refresh of the datapilot the results are messed up. Reassigned to spec owner.
This doesn't seem all that important, so the target can be changed to 3.0.
Niklas:I have seen the spec and issue's comment,when I restart dataplilot again,click OK button,the calc will popup a dialog,the dialog text is "the destination range is not empty.Overwrite existing contents?".I think it is not a problem from above text.Do you think about it?
taking the issue.
Started.
Created attachment 61879 [details] Update the patch.
What I had in mind was to change the behavior only if the output table would otherwise overwrite its source data. With the patch, the output is only ever moved down, never up. If there is space available, it's intended behavior to add page fields or the filter button above the existing table, so the data area of the output starts at the same position as before.
Created attachment 62062 [details] Update the patch.
The check if the new area is editable and empty, and the CopyToDocument call for undo must be done with the changed output area.
Created attachment 62152 [details] Update the patch again.
Created attachment 62279 [details] Update the patch.
"pOutput->SetPosition" should be after CreateOutput. pOutput is set because of GetNewOutputRange, but ScDPObject::Output shouldn't rely on that. More importantly, the new position for aNewOut is wrong. In the example, if the output is originally at A22 instead of A23, data is still overwritten. Also, you should check if aNewOut is still valid and not outside of the sheet.
Created attachment 62394 [details] Update the patch.
taking the issue
I added the last patch to CWS "calc50".
reassigning to QA for verification
verified in internal build cws_calc50
Verified in DEV300m51 Closing