Table Transformer can not read column name correctly after published but pre-view is ok
Asked by Alice Liu:

Hi there,

I encountered an issue which previously did not happen for using 2-layer Table Transformer structure. My structure is as below:

Table Transformer 1

Select T1.'Top'

Table Transformer 2

Select ROWNUM() AS 'Top'

The issue is that Confluence can not read 'Top' after published (as below image), but in Table Transformer 1's pre-view it is ok with desired result (as below image).

Could you suggest how to fix it?

Thank you.

![captainM_0918.png](https://community.atlassian.com/t5/image/serverpage/image-id/281098i7A899C8BC9C195EA/image-size/large?v=v2&px=999 "captainM_0918.png")

![captainM_0918-2.png](https://community.atlassian.com/t5/image/serverpage/image-id/281099iC3B4455A1635C8EF/image-size/large?v=v2&px=999 "captainM_0918-2.png")


Answers:
author: Katerina Rudkovskaya [Stiltsoft]
body: Hi @\[deleted\],  

I've tried to recreate your case, and everything works fine for me, here is my published page:  

![Mon 5-1.png](https://community.atlassian.com/t5/image/serverpage/image-id/281330i5DB3FB83FAE85E50/image-size/large?v=v2&px=999 "Mon 5-1.png")  

And here is my macro structure:  

![Mon 5-2.png](https://community.atlassian.com/t5/image/serverpage/image-id/281331i264ABBD070475EF4/image-size/large?v=v2&px=999 "Mon 5-2.png")  
Here goes the internal Table Transformer macro:  

SELECT  
ROWNUM() AS 'Top',  
\*  
FROM T\*  

![Mon 5-3.png](https://community.atlassian.com/t5/image/serverpage/image-id/281332iCC678F9146FB6FE8/image-size/large?v=v2&px=999 "Mon 5-3.png")  

And here goes the external Table Transformer macro:  
SELECT T1.'Top',  
T1.'Project',  
T1.'Column 1',  
T2.'Column 3'  
FROM T1  
JOIN T2 ON T1.'Project' = T2.'Project'  

![Mon 5-4.png](https://community.atlassian.com/t5/image/serverpage/image-id/281333i79CDA3481993B687/image-size/large?v=v2&px=999 "Mon 5-4.png")  

Unfortunately, I don't see your source tables and full SQL queries. Check everything once more and type your queries using autocomplete (type T1. and wait for the dropdown with available columns to choose from).  

You may also check the version of the app for Date Center/Server -- the current one is 9.12.0, please update if yours is older.  

If you are still stuck, please refer to [our support](https://stiltsoft.atlassian.net/servicedesk/customer/portal/14). Attach the Page Storage Format (upper right corner of the page -\> menu ... -\> View storage format) so we'll be able to recreate exactly your page and investigate the issue.

comments: author: Alice Liu
body: Hi Katerina,

Thank you for the feedback. The structure you reproduce matches my case, and the major difference I think is that actually the T1 and T2 in my case are more complicated, which are generated from several sub-tables using "table excerpt" tool for leveraging. The complete structure is as below images FYI.

For the SQL queries, I checked with autocomplete and all columns can be found. Also the result can successfully show in Table Transformer's preview when in Confluence edit mode, so I think it is not syntax or logic issue of SQL queries, but rather other reasons that may be related to compatibility with other macros, such as Table Filter and Table excerpt/excerpt include, or app version like you mentioned.

Would you like to provide some comments/insights on the compatibility issue part?

For app version, I'm trying to contact our Confluence admin to check.

Thank you.

ps. I wish I could use more simple structure, but consider our application, data source comes from another macro "Confiforms" and SQL rules, This is so far the best way I can think of to meet our needs. It is so close to full solution that we made it in the preview... really hope it can be seen on published page too.

![img-1.png](https://community.atlassian.com/t5/image/serverpage/image-id/281726i5FC1B87EE3E951F1/image-size/large?v=v2&px=999 "img-1.png")

![img-3.png](https://community.atlassian.com/t5/image/serverpage/image-id/281724iAEBF7EF1782246FD/image-size/large?v=v2&px=999 "img-3.png")![img-2.png](https://community.atlassian.com/t5/image/serverpage/image-id/281725i0E194885B6085B52/image-size/large?v=v2&px=999 "img-2.png")


author: Stiltsoft support
body: Hi [@Alice Liu](/t5/user/viewprofilepage/user-id/5213119) ,

Just the same advice from our side: check the app's version and update it to the latest one (we constantly improve internal processes regarding caches, compatibility with other apps, for example, Confiforms that you've mentioned - maybe it will help your case).

To investigate the issue deeper (for the preview the macro works with static snapshots of your data but somehow the live macros cause trouble) you need to refer to our support and attach the page storage format not only of the master page but all the child pages containing your Table Excerpt macros and Confiforms macros.

So, we'll be able to recreate the whole chain an see where (and why) the macro is "confused". And maybe we'll be able to suggest how to simplify your structure in general.


Tags: filter

table

unknown-hosting-type