Assuming the following TWiki tables.
| ID | Client | Worker | Effort | Life Time | Date | State |
| 1 | Client 3 | Worker 3 | 3 | 6 | 2007/6/16 | State1 |
| 2 | Client 3 | Worker 3 | 9 | 9 | 2007/4/3 | State3 |
| 3 | Client 2 | Worker 2 | 8 | 7 | 2007/8/19 | State3 |
| 4 | Client 4 | Worker 1 | 9 | 7 | 2007/11/10 | State2 |
| 5 | Client 1 | Worker 2 | 6 | 11 | 2007/2/17 | State2 |
| 6 | Client 1 | Worker 1 | 5 | 6 | 2007/12/5 | State2 |
| 7 | Client 4 | Worker 1 | 7 | 7 | 2007/1/19 | State3 |
| 8 | Client 3 | Worker 2 | 4 | 11 | 2007/11/16 | State1 |
| 9 | Client 4 | Worker 3 | 2 | 7 | 2007/2/13 | State3 |
| 10 | Client 2 | Worker 2 | 2 | 6 | 2007/12/16 | State1 |
| 11 | Client 3 | Worker 2 | 7 | 10 | 2007/3/28 | State1 |
| 12 | Client 4 | Worker 3 | 1 | 10 | 2007/12/30 | State2 |
| 13 | Client 4 | Worker 2 | 2 | 9 | 2007/11/17 | State1 |
| 14 | Client 3 | Worker 2 | 4 | 7 | 2007/10/2 | State2 |
| 15 | Client 1 | Worker 2 | 4 | 2 | 2007/10/25 | State2 |
Operations.
Count
You type:
%FLUIDPIVOTS{name="examplePivot1" table="exampleTable1" rows="Worker" columns="Client" data="Client" operation="count"}%
%CHART{type="bar" name="bar1" table="examplePivot1" data="R3:C2..R6:C6" xaxis="R3:C1..R6:C1" legend="R2:C2..R2:C6" width="400" height="200" ymin="0" ylabel="Cases" xlabel="Worker" yaxis="on"}%
You get:
| Client - count | Client |
| Worker | Client 3 | Client 4 | Client 1 | Client 2 | Totals |
| Worker 2 | 3 | 1 | 2 | 2 | 8 |
| Worker 3 | 2 | 2 | 0 | 0 | 4 |
| Worker 1 | 0 | 2 | 1 | 0 | 3 |
| Totals | 5 | 5 | 3 | 2 | 15 |
Sum
You type:
%FLUIDPIVOTS{name="examplePivot2" table="exampleTable1" rows="Worker" columns="Client" data="Effort" operation="sum"}%
%CHART{type="bar" name="bar2" table="examplePivot2" data="R3:C2..R6:C6" xaxis="R3:C1..R6:C1" legend="R2:C2..R2:C6" width="400" height="200" ymin="0" ylabel="Effort Time - sum" xlabel="Worker" yaxis="on"}%
You get:
| Effort - sum | Client |
| Worker | Client 3 | Client 4 | Client 1 | Client 2 | Totals |
| Worker 2 | 15 | 2 | 10 | 10 | 37 |
| Worker 1 | 0 | 16 | 5 | 0 | 21 |
| Worker 3 | 12 | 3 | 0 | 0 | 15 |
| Totals | 27 | 21 | 15 | 10 | 73 |
Average
You type:
%FLUIDPIVOTS{name="examplePivot3" table="exampleTable1" rows="Worker" columns="Client" data="Effort" operation="average"}%
%CHART{type="bar" name="bar3" table="examplePivot3" data="R3:C2..R6:C6" xaxis="R3:C1..R6:C1" legend="R2:C2..R2:C6" width="400" height="200" ymin="0" ylabel="Effort Time - average" xlabel="Worker" yaxis="on"}%
You get:
| Effort - average | Client |
| Worker | Client 3 | Client 1 | Client 2 | Client 4 | Totals |
| Worker 1 | 0 | 5 | 0 | 8 | 7 |
| Worker 2 | 5 | 5 | 5 | 2 | 4.625 |
| Worker 3 | 6 | 0 | 0 | 1.5 | 3.75 |
| Totals | 5.4 | 5 | 5 | 4.2 | 4.867 |
Min
You type:
%FLUIDPIVOTS{name="examplePivot4" table="exampleTable1" rows="Worker" columns="Client" data="Effort" operation="min"}%
%CHART{type="bar" name="bar4" table="examplePivot4" data="R3:C2..R6:C6" xaxis="R3:C1..R6:C1" legend="R2:C2..R2:C6" width="400" height="200" ymin="0" ylabel="Effort Time - min" xlabel="Worker" yaxis="on"}%
You get:
| Effort - min | Client |
| Worker | Client 1 | Client 3 | Client 2 | Client 4 | Totals |
| Worker 1 | 5 | 0 | 0 | 7 | 5 |
| Worker 2 | 4 | 4 | 2 | 2 | 2 |
| Worker 3 | 0 | 3 | 0 | 1 | 1 |
| Totals | 4 | 3 | 2 | 1 | 1 |
Max
You type:
%FLUIDPIVOTS{name="examplePivot5" table="exampleTable1" rows="Worker" columns="Client" data="Effort" operation="max"}%
%CHART{type="bar" name="bar5" table="examplePivot5" data="R3:C2..R6:C6" xaxis="R3:C1..R6:C1" legend="R2:C2..R2:C6" width="400" height="200" ymin="0" ylabel="Effort Time - max" xlabel="Worker" yaxis="on"}%
You get:
| Effort - max | Client |
| Worker | Client 3 | Client 4 | Client 2 | Client 1 | Totals |
| Worker 3 | 9 | 2 | 0 | 0 | 9 |
| Worker 1 | 0 | 9 | 0 | 5 | 9 |
| Worker 2 | 7 | 2 | 8 | 6 | 8 |
| Totals | 9 | 9 | 8 | 6 | 9 |
Var
You type:
%FLUIDPIVOTS{name="examplePivot6" table="exampleTable1" rows="Worker" columns="Client" data="Effort" operation="var"}%
%CHART{type="bar" name="bar6" table="examplePivot6" data="R3:C2..R6:C6" xaxis="R3:C1..R6:C1" legend="R2:C2..R2:C6" width="400" height="200" ymin="0" ylabel="Effort Time - var" xlabel="Worker" yaxis="on"}%
You get:
| Effort - var | Client |
| Worker | Client 4 | Client 2 | Client 3 | Client 1 | Totals |
| Worker 3 | 0.25 | 0 | 9 | 0 | 9.688 |
| Worker 2 | 0 | 9 | 2 | 1 | 4.234 |
| Worker 1 | 1 | 0 | 0 | 0 | 2.667 |
| Totals | 10.16 | 9 | 5.04 | 0.667 | 6.649 |
Dev
You type:
%FLUIDPIVOTS{name="examplePivot7" table="exampleTable1" rows="Worker" columns="Client" data="Effort" operation="dev"}%
%CHART{type="bar" name="bar7" table="examplePivot7" data="R3:C2..R6:C6" xaxis="R3:C1..R6:C1" legend="R2:C2..R2:C6" width="400" height="200" ymin="0" ylabel="Effort Time - dev" xlabel="Worker" yaxis="on"}%
You get:
| Effort - dev | Client |
| Worker | Client 4 | Client 2 | Client 3 | Client 1 | Totals |
| Worker 3 | 0.5 | 0 | 3 | 0 | 3.112 |
| Worker 2 | 0 | 3 | 1.414 | 1 | 2.058 |
| Worker 1 | 1 | 0 | 0 | 0 | 1.633 |
| Totals | 3.187 | 3 | 2.245 | 0.816 | 2.579 |
Table Origin
Local
You type:
%FLUIDPIVOTS{name="examplePivot8" table="exampleTable1" rows="Worker" columns="Client" data="Effort" operation="sum"}%
You get:
| Effort - sum | Client |
| Worker | Client 3 | Client 4 | Client 1 | Client 2 | Totals |
| Worker 2 | 15 | 2 | 10 | 10 | 37 |
| Worker 1 | 0 | 16 | 5 | 0 | 21 |
| Worker 3 | 12 | 3 | 0 | 0 | 15 |
| Totals | 27 | 21 | 15 | 10 | 73 |
Extern
You type:
%FLUIDPIVOTS{name="examplePivot9" table="exampleTable1" web="TWiki" topic="FluidPivotsPluginExtern" rows="Worker" columns="Client" data="Effort" operation="sum"}%
You get:
| Effort - sum | Client |
| Worker | Client 3 | Client 2 | Client 4 | Client 1 | Totals |
| Worker 3 | 11 | 8 | 6 | 0 | 25 |
| Worker 2 | 16 | 0 | 6 | 0 | 22 |
| Worker 1 | 2 | 15 | 0 | 5 | 22 |
| Totals | 29 | 23 | 12 | 5 | 69 |
Integrations
Remember that you have to set the correct order on
{PluginsOrder} in the configuration page,
FluidPivotsPlugin should run before
ChartPlugin.
You type:
%FLUIDPIVOTS{name="examplePivot10" table="exampleTable1" rows="Worker" columns="Client" data="Effort" operation="sum"}%
%CHART{type="bar" name="bar1" table="examplePivot10" data="R3:C2..R6:C6" xaxis="R3:C1..R6:C1" legend="R2:C2..R2:C6" width="400" height="200" ymin="0" ylabel="Effort Time" xlabel="Worker" yaxis="on"}%
You get:
| Effort - sum | Client |
| Worker | Client 3 | Client 4 | Client 1 | Client 2 | Totals |
| Worker 2 | 15 | 2 | 10 | 10 | 37 |
| Worker 1 | 0 | 16 | 5 | 0 | 21 |
| Worker 3 | 12 | 3 | 0 | 0 | 15 |
| Totals | 27 | 21 | 15 | 10 | 73 |
Properties
Visible
You type:
%FLUIDPIVOTS{name="examplePivot11" table="exampleTable1" rows="Worker" columns="Client" data="Effort" operation="sum" visible="col"}%
%FLUIDPIVOTS{name="examplePivot12" table="exampleTable1" rows="Worker" columns="Client" data="Effort" operation="sum" visible="row"}%
%FLUIDPIVOTS{name="examplePivot13" table="exampleTable1" rows="Worker" columns="Client" data="Effort" operation="sum" visible="data"}%
You get:
| Effort - sum | Client |
| Worker | Client 3 | Client 4 | Client 1 | Client 2 |
| Totals | 27 | 21 | 15 | 10 |
| Effort - sum | Client |
| Worker | Client 3 | Client 4 | Client 1 | Client 2 |
| Worker 2 | 15 | 2 | 10 | 10 |
| Worker 1 | 0 | 16 | 5 | 0 |
| Worker 3 | 12 | 3 | 0 | 0 |
Maxrow
You type:
%FLUIDPIVOTS{name="examplePivot14" table="exampleTable1" rows="Worker" columns="Client" data="Effort" operation="sum" maxrow="2"}%
You get:
| Effort - sum | Client |
| Worker | Client 3 | Client 4 | Client 1 | Client 2 | Totals |
| Worker 2 | 15 | 2 | 10 | 10 | 37 |
| Otros | 12 | 19 | 5 | 0 | 36 |
| Totals | 27 | 21 | 15 | 10 | 73 |
Maxcol
You type:
%FLUIDPIVOTS{name="examplePivot15" table="exampleTable1" rows="Worker" columns="Client" data="Effort" operation="sum" maxcol="3"}%
You get:
| Effort - sum | Client |
| Worker | Client 3 | Client 4 | Otros | Totals |
| Worker 2 | 15 | 2 | 20 | 37 |
| Worker 1 | 0 | 16 | 5 | 21 |
| Worker 3 | 12 | 3 | 0 | 15 |
| Totals | 27 | 21 | 25 | 73 |
Order
You type:
%FLUIDPIVOTS{name="examplePivot16" table="exampleTable1" rows="Worker" columns="Client" data="Effort" operation="sum" order="max"}%
%FLUIDPIVOTS{name="examplePivot17" table="exampleTable1" rows="Worker" columns="Client" data="Effort" operation="sum" order="min"}%
%FLUIDPIVOTS{name="examplePivot18" table="exampleTable1" rows="Worker" columns="Client" data="Effort" operation="sum" order="off"}%
You get:
| Effort - sum | Client |
| Worker | Client 3 | Client 4 | Client 1 | Client 2 | Totals |
| Worker 2 | 15 | 2 | 10 | 10 | 37 |
| Worker 1 | 0 | 16 | 5 | 0 | 21 |
| Worker 3 | 12 | 3 | 0 | 0 | 15 |
| Totals | 27 | 21 | 15 | 10 | 73 |
| Effort - sum | Client |
| Worker | Client 2 | Client 1 | Client 4 | Client 3 | Totals |
| Worker 3 | 0 | 0 | 3 | 12 | 15 |
| Worker 1 | 0 | 5 | 16 | 0 | 21 |
| Worker 2 | 10 | 10 | 2 | 15 | 37 |
| Totals | 10 | 15 | 21 | 27 | 73 |
| Effort - sum | Client |
| Worker | Client 1 | Client 2 | Client 3 | Client 4 | Totals |
| Worker 1 | 5 | 0 | 0 | 16 | 21 |
| Worker 2 | 10 | 10 | 15 | 2 | 37 |
| Worker 3 | 0 | 0 | 12 | 3 | 15 |
| Totals | 15 | 10 | 27 | 21 | 73 |
Cachetime
You type:
%FLUIDPIVOTS{name="examplePivot19" table="exampleTable1" rows="Worker" columns="Client" data="Effort" operation="sum" cachetime="100"}%
You get:
| Effort - sum | Client |
| Worker | Client 3 | Client 4 | Client 1 | Client 2 | Totals |
| Worker 2 | 15 | 2 | 10 | 10 | 37 |
| Worker 1 | 0 | 16 | 5 | 0 | 21 |
| Worker 3 | 12 | 3 | 0 | 0 | 15 |
| Totals | 27 | 21 | 15 | 10 | 73 |
Ignorecache
You type:
%FLUIDPIVOTS{name="examplePivot19" table="exampleTable1" rows="Worker" columns="Client" data="Effort" operation="sum" ignorecache="1"}%
You get:
| Effort - sum | Client |
| Worker | Client 3 | Client 4 | Client 1 | Client 2 | Totals |
| Worker 2 | 15 | 2 | 10 | 10 | 37 |
| Worker 1 | 0 | 16 | 5 | 0 | 21 |
| Worker 3 | 12 | 3 | 0 | 0 | 15 |
| Totals | 27 | 21 | 15 | 10 | 73 |
On Error
Wrong table.
You type:
%FLUIDPIVOTS{name="examplePivot20" table="exampleTable1SOMEERROR" rows="Worker" columns="Client" data="Effort" operation="sum" cachetime="1"}%
You get:
FluidPivotsPlugin error: parameter table is not valid table; the specified table 'exampleTable1SOMEERROR' does not exist.
Big Example
You type:
%FLUIDPIVOTS{name="examplePivot51" table="exampleTable2" web="TWiki" topic="FluidPivotsPluginExtern" rows="Data1" columns="Data2" data="Effort" operation="sum"}%
%FLUIDPIVOTS{name="examplePivot52" table="exampleTable2" web="TWiki" topic="FluidPivotsPluginExtern" rows="Data1" columns="Data2" data="Effort" operation="sum" maxrow="10"}%
%FLUIDPIVOTS{name="examplePivot53" table="exampleTable2" web="TWiki" topic="FluidPivotsPluginExtern" rows="Data1" columns="Data2" data="Time" operation="sum" maxcol="10"}%
%FLUIDPIVOTS{name="examplePivot54" table="exampleTable2" web="TWiki" topic="FluidPivotsPluginExtern" rows="Data1" columns="Data2" data="Time" operation="sum" maxrow="10" maxcol="10"}%
%FLUIDPIVOTS{name="examplePivot55" table="exampleTable2" web="TWiki" topic="FluidPivotsPluginExtern" rows="Data1" columns="Data2" data="Time" operation="sum" visible="data"}%
%FLUIDPIVOTS{name="examplePivot56" table="exampleTable2" web="TWiki" topic="FluidPivotsPluginExtern" rows="Data1" columns="Data2" data="Time" operation="sum" visible="row" order="off"}%
%FLUIDPIVOTS{name="examplePivot57" table="exampleTable2" web="TWiki" topic="FluidPivotsPluginExtern" rows="Data1" columns="Data2" data="Time" operation="sum" visible="row" order="max"}%
%FLUIDPIVOTS{name="examplePivot58" table="exampleTable2" web="TWiki" topic="FluidPivotsPluginExtern" rows="Data1" columns="Data2" data="Time" operation="sum" visible="row" order="min"}%
%FLUIDPIVOTS{name="examplePivot59" table="exampleTable2" web="TWiki" topic="FluidPivotsPluginExtern" rows="Data1" columns="Data2" data="Time" operation="sum" visible="col" maxrow="15"}%
%FLUIDPIVOTS{name="examplePivot60" table="exampleTable2" web="TWiki" topic="FluidPivotsPluginExtern" rows="Data1" columns="Data2" data="Time" operation="sum" visible="row" maxcol="15"}%
%CHART{type="bar" name="bar59" table="examplePivot59" data="R3:C2..R100:C2" xaxis="R3:C1..R100:C1" legend="R2:C2..R2:C2" width="800" height="200" ymin="0" ylabel="Data2" xlabel="Data1" yaxis="on"}%
%CHART{type="bar" name="bar60" table="examplePivot60" data="R3:C2..R3:C100" xaxis="R2:C2..R2:C100" legend="R3:C1..R3:C1" width="800" height="200" ymin="0" ylabel="Data1" xlabel="Data2" yaxis="on"}%
You get:
| Effort - sum | Data2 |
| Data1 | 15 | 6 | 12 | 7 | 18 | 10 | 13 | 14 | 11 | 16 | 1 | 19 | 4 | 5 | 9 | 17 | 2 | 8 | 0 | 3 | Totals |
| 19 | 38 | 38 | 19 | 19 | 57 | 19 | 19 | 38 | 0 | 38 | 19 | 0 | 0 | 19 | 0 | 0 | 0 | 0 | 0 | 0 | 323 |
| 18 | 36 | 0 | 54 | 18 | 0 | 0 | 18 | 36 | 18 | 0 | 0 | 0 | 18 | 0 | 36 | 18 | 0 | 18 | 0 | 0 | 270 |
| 17 | 34 | 17 | 17 | 17 | 0 | 34 | 0 | 17 | 17 | 0 | 0 | 0 | 0 | 17 | 17 | 17 | 0 | 0 | 17 | 0 | 221 |
| 16 | 16 | 16 | 32 | 0 | 0 | 16 | 16 | 0 | 16 | 0 | 32 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 144 |
| 13 | 13 | 13 | 0 | 13 | 0 | 0 | 0 | 0 | 0 | 13 | 13 | 0 | 0 | 26 | 13 | 0 | 13 | 0 | 0 | 0 | 117 |
| 14 | 14 | 0 | 0 | 0 | 14 | 28 | 0 | 0 | 14 | 0 | 0 | 14 | 14 | 0 | 14 | 0 | 0 | 0 | 0 | 0 | 112 |
| 10 | 0 | 0 | 0 | 0 | 20 | 10 | 0 | 0 | 0 | 10 | 10 | 10 | 10 | 10 | 0 | 0 | 10 | 10 | 0 | 10 | 110 |
| 15 | 0 | 30 | 0 | 15 | 15 | 0 | 0 | 0 | 0 | 0 | |
|---|