Tablix columns continue onto the next page leaving a lot of empty space

Posted by: jacek.balajewicz on 11 March 2025, 4:06 pm EST

  • Posted 11 March 2025, 4:06 pm EST - Updated 11 March 2025, 4:13 pm EST

    I am working on recreating a report that requires a pivot:

    • NDC column is sorted in ascending order and there are many NDC columns
    • Store # column can have one of more “stores” (2 in this example)

    I was able to build the report using a tablix. However, the consecutive NDC report columns run horizontally until they reach the width of the page and then continue onto the next page. This leaves a lot of empty space on each page when there are just a few “Store” rows.

    An obvious fix of sorts would be to reverse the rows and columns. Unfortunately, this is not an option as the objective is to match the flow of the original report pictured above.

    How can I configure this report to keep adding consecutive columns on the same page until there is no more room left vertically?



  • Posted 13 March 2025, 2:54 am EST - Updated 13 March 2025, 3:03 am EST

    Hi Jacek,

    To show a data in a Tablix and have it expand to multiple rows like that you would have to nest the Tablix in Table Group or a List(or Banded List).

    Also, To group the Data in a Table/List you would need a group node which will be used for grouping the Tablix Content.

    Sample Data Structure:

    [{ "ndc": "00001-0001-01",  "store": "07",  "total": 120,  "group": "A"    },
     { "ndc": "00001-0001-01",  "store": "08",  "total": 350,  "group": "A"    },
     { "ndc": "00002-0002-02",  "store": "07",  "total": 45,   "group": "A"    },
     { "ndc": "00002-0002-02",  "store": "08",  "total": 220,  "group": "B"   }]
    

    This group will be used to show multiple Tablix Controls one for each group.

    Based on this Group Value please set the Table Group Expression or the List Detail Grouping Expression and add the Tablix in the Control.

    For reference, I have created a sample report and attached it along with. In the sample I am grouping with expression:

    {Floor(id/14)}
    and id just iterates on data from 0 to ‘n’

    Tablix.zip

  • Posted 17 March 2025, 12:45 pm EST

    Hi Akshay,

    Thank you very much for your suggestion and the attached example. I added the “ID” data element to my data set to be from 0 to n the way you described. I implemented the grouping and the floor() function. I am still not getting the desired output. With a small number of “stores” like in the example above the report doesn’t use the space below the table (vertically). It continues on to the new page horizontally instead just like the last screenshot I posted above.

    I am rather confused at this point as to why your solution doesn’t work in my scenario. Could you confirm if in the function

    {Floor(id/14)}

    14 stands for the number of columns for the 2 stores? The number of stores will be variable in this report. I can get the number of stores for the Floor() function to modify it this way

    {Floor(id / CountDistinct(Store) * 7)}

    No matter what I tried with any of these calculations the report still won’t output more than one table per page.

    Could this be caused by the version of Active Reports JS? My organization doesn’t use the latest version available.

  • Posted 19 March 2025, 4:45 am EST

    Hi Jacek,

    I used 14 because in my report in each tablix there are 14 records (7 columns 2 row = 14 entries).

    It is unlikely that the issue is caused because of different versions. It is likely occurring because of the different data structure or aggregation in the Tablix.

    I only used the count for sample data but I would suggest you to group the fields with valid data fields if possible.

    Please share your report and dummy data so we can test this issue at our end and gete back to you accordingly.

  • Posted 31 March 2025, 5:31 pm EST

    Hi Akshay,

    This report required a different approach in the end. Essentially, a “store” may or may not have data for a given “NDC”. There was no option to add this data to make sure there was a row for each store/NDC combination.

    Thank you for your help!

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels