Can I use Table Transformer to transpose each table before using Table Excerpt Include?

Pei-ju Hsu August 12, 2021

I saw a way to use Table Transformer to transpose the table after using Table Excerpt Include in this discussion: https://community.atlassian.com/t5/Confluence-questions/Select-table-rows-in-other-page/qaq-p/1759006

Is there a way to do the opposite, i.e., transpose each table first then use Table Excerpt Include? Thank you.

For example, the 2 tables in Table Excerpt are:

A | x1              A | x2

B | y1              B | y2

C | z1              C | z2

And I'd like to have the result looks like

A  |  B  |  C

x1 | y1 | z1

x2 | y2 | z2

It seems the Table Excerpt Include doesn't support merging table by first column but only by first row. If it can support merging table by first column, that can be the solution as well.

1 answer

1 accepted

6 votes
Answer accepted
Katerina Kovriga {Stiltsoft}
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
August 12, 2021

Hi @Pei-ju Hsu ,

You may implement the following steps:

Fri 1-1.png

Here we have your tables that are collected with the help of the Table Excerpt Include macro:

Fri 1-2.pngThe last step is to merge your transposed tables via the Table Transformer macro.

Here we choose the standard Merge preset:

Fri 1-3.pngAnd here check the Transpose source tables option:

Fri 1-4.png

And here is your result:

Fri 1-5.png

Hope this helps your case.

Pei-ju Hsu August 13, 2021

Hi Katerina,

Thank you for the quick response. Yes, this is what I'm looking for. I test it again and it works well. Thank you!

A small feedback -- when I was testing the tool the first time, I was using the case when the first rows of 2 tables are the same (like below). In this case the tool is merging 2 tables by first row but not first column by default.

A | x1              A | x1

B | y1               B | y2

C | z1               C | z2

Katerina Kovriga {Stiltsoft}
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
August 13, 2021

It is because the Merge preset is chosen by default for the Table Transformer macro (it comes first in line), so the first row (similar for the two tables) was misinterpreted as a header row.

Thank you for reaching out, I'm glad that everything works now.

Pei-ju Hsu September 2, 2021

Hi Katerina,

Thank you again for your help. I have a follow up question:

I'd like to add "Show page meta data: Page" in Table Excerpt Include macro. How to make it work with Table Transformer like the following?

 

Page   |  A  |  B  |  C

page1 | x1 | y1 | z1

page2 | x2 | y2 | z2

 

Thank you,

Pei-ju

Katerina Kovriga {Stiltsoft}
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
September 2, 2021

You won't be able to construct a beautiful table with the page meta data if you need to transpose tables as we performed for your case - you tables will be messed up.

Create source tables horizontally

A |B  |C

x1|y1|z1

Collect them with the Table Excerpt Include macro (check the "Show as a report table"  option) and choose to show any meta data you want.

Everything will be shown beautifully and you even won't need the Table Transformer macro at all.

eaugust_oxio_io
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
January 25, 2022

The table looks perfect until I add a page name, which should just appear as a the first column. Is this on the roadmap to be fixed? 

Katerina Kovriga {Stiltsoft}
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
January 25, 2022

Hi @eaugust_oxio_io ,

If you mean that the table with meta data coming after the Table Excerpt Include macro has beautifully merged cells (the first table on the screenshot) and after the Table Transformer macro the cells are splitted (the second table on the screenshot), then it's not a bug: the Table Transformer macro is based on the AlaSQL library and refers to every table cell as an entry of a SQL database. So it can't operate with any merged info.

Wed 13-1.png

So try not to use the Table Transformer macro on top of the Table Excerpt Include macro if it is not necessary - check the Show as a report table option in the Table Excerpt Include macro to get a combined report.

Stiltsoft support
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
August 22, 2024

Please check the new Transpose tables option in the Table Excerpt Include macro: https://docs.stiltsoft.com/tfac/cloud/table-excerpt-and-table-excerpt-include-42241623.html#TableExcerptandTableExcerptInclude-TransposingTables

This option excludes the Table Transformer macro and simplifies the case.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events