Difficulty

From Apache OpenOffice Wiki
Jump to: navigation, search



Difficulty

Normally, you create a reference to a value by entering the address of the cell that contains the value. For example, the formula =C6*2 creates a reference to cell C6 and returns the doubled value.

If this cell is located in the results area of a Pivot Table, it contains the result that was calculated by referencing specific categories of the row and column fields. In Figure 239, cell C6 contains the sum of the sales values of the employee Hans in the Sailing category. The formula in the cell C12 uses this value.

AOO41CG08 239.png
Figure 239: Formula reference to a cell of the Pivot Table
Documentation caution.png If the underlying data or the layout of the Pivot Table changes, you must be mindful that the sales value for Hans might appear in a different cell. Your formula still references the cell C6 and, therefore, uses the wrong value.

The correct value is in a different location. For example, in Figure 240, the location is now C7 because the employee Fritz is included in the Pivot Table.

AOO41CG08 240.png
Figure 240: The value that you really want to use can be found now in a different location.

The function GETPIVOTDATA allows you to have a reference to a value inside the Pivot Table by using the specific identifying categories of that value.

Content on this page is licensed under the Creative Common Attribution 3.0 license (CC-BY).
Personal tools