Example
This table:
|
a |
b |
c |
|---|---|---|
|
d |
e |
f |
|
g |
h |
i |
Should become this:
|
a |
d |
g |
|
b |
e |
h |
|
c |
f |
i |
How To
-
Go to the PocketQuery Administration
-
Go to "Templates" and click on "Add template"
-
Name it "pivot" and copy & paste following code into "content"
<table class="aui confluenceTable pocketquery-table"> <tbody> #foreach ($column in $columns) <tr> <td style="background-color: #f0f0f0; font-weight: bold;"> $column </td> #foreach($row in $result) <td> $!row.get($column) </td> #end </tr> #end </tbody> </table> -
Go to a query and select "pivot" as template