# How can I format my report in Ignition to have two columns?

**URL:** <https://forum.inductiveautomation.com/t/how-can-i-format-my-report-in-ignition-to-have-two-columns/102735>\
**Category:** Ignition\
**Created:** [February 22, 2025, 7:26pm UTC](https://forum.inductiveautomation.com/t/how-can-i-format-my-report-in-ignition-to-have-two-columns/102735 "2025-02-22T19:26:51Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![cmarin](https://avatars.discourse-cdn.com/v4/letter/c/67e7ee/32.png) [@cmarin](https://forum.inductiveautomation.com/u/cmarin)\
**Post date:** [February 22, 2025, 7:26pm UTC](https://forum.inductiveautomation.com/t/how-can-i-format-my-report-in-ignition-to-have-two-columns/102735/1 "2025-02-22T19:26:51Z")

</div>

I am designing a report in Ignition Report Designer where the data comes from an SQL query, and the number of rows varies dynamically. Currently, if the table has many rows, the content simply extends downward and jumps to a new page when it fills up. However, what I need is for the content to first fill the first column, then continue in the second column on the same page, and if there is still more data, move to the next page and repeat the process.

I couldn't find the **Column Count** option in the **Property Inspector**. Is there a native way to achieve this behavior in Ignition, or do I need to handle it manually (e.g., using two lists and filtering the data)?

I appreciate any help or suggestions. Thank you!

---

<div class="post-metadata">

**Author:** ![Chris\_Bingham](https://avatars.discourse-cdn.com/v4/letter/c/e5b9ba/32.png) [@Chris\_Bingham](https://forum.inductiveautomation.com/u/Chris_Bingham)\
**Post date:** [February 23, 2025, 1:39am UTC](https://forum.inductiveautomation.com/t/how-can-i-format-my-report-in-ignition-to-have-two-columns/102735/2 "2025-02-23T01:39:55Z")

</div>

To avoid post-processing of the data, I would try to return the data in the desired format within your SQL query.

> **Example Query (assuming 50 rows per page)**
>
> ```python
> -- Declare variable number of rows to group values by:
> DECLARE @GroupByRows INT;
> SET @GroupByRows = 50;
> 
> -- Add an index column to original data query:
> WITH Indexed_Data AS (
> SELECT
> [your_column_name_here] AS Col_Data,
> ROW_NUMBER() OVER (ORDER BY [your_column_name_here]) AS Orig_Row
> FROM [your_table_name_here]
> ),
> -- Extract values destined for Column1, assign new row number unique to this column:
> Col1 AS (
> SELECT
> Col_Data,
> ROW_NUMBER() OVER (ORDER BY (SELECT 1)) AS Col1_Row
> FROM Indexed_Data
> WHERE (Orig_Row - 1) / @GroupByRows % 2 = 0
> ),
> -- Extract values destined for Column2, assign new row number unique to this column:
> Col2 AS (
> SELECT
> Col_Data,
> ROW_NUMBER() OVER (ORDER BY (SELECT 1)) AS Col2_Row
> FROM Indexed_Data
> WHERE (Orig_Row - 1) / @GroupByRows % 2 = 1
> )
> -- Join all columns to single table:
> SELECT 
> Col1.Col_Data AS Col_Data,
> Col2.Col_Data AS Col_Data_Continued
> FROM Col1
> LEFT JOIN Col2
> ON Col1.Col1_Row = Col2.Col2_Row
> ORDER BY Col1.Col1_Row;
> 
> ```

With this query, you could also change "GroupByRows" to 1 in order to alternate values between two columns (where the first value appears in "Col1", the second value in "Col2", the third in "Col1", the fourth in "Col2", etc. This might avoid the trial-and-error that would be required to get the correct number of rows per page, at the expense of 'synchronous' data.
