Use Case

You need to derive the content from a column of another macro output used as a source table (e.g. Jira Issues macro, Page Properties Report, Task Report, etc.).

Solution

  1. Switch the page to the edit mode.

  2. Insert the Table Transformer macro and paste the table or the macros outputting tables within the macro body.

  3. Select the macro and click Edit.

  4. In the Presets tab select Custom transformation and click Next.

  5. Enter the following SQL query pattern:

    SELECT SUBSTRING_VIEW(T1.'Key',5,4) as 'OTS Key',
     T1.'Assignee',T1.'T',T1.'Created' FROM T1
    
    /* SYNTAX - SUBSTRING_VIEW('YOUR COLUMN NAME', STARTING POSITION NUMBER, THE NUMBER OF CHARACTERS TO DERIVE) */
    SQL
  6. Click Next

  7. Save the macro and the page.

The SUBSTRING_VIEW function allows to not only extract the content of a column, but also retain the original formatting of the source (cell) so that it could be applied to the altered output, including links retaining (see screenshots)