Forum How do I...?

Big Tables, Long Rowspans

We are having difficulty paginating long tables where large rowspans occur.

Let's assume we have a table that is 100 rows long with THEAD and TBODY attributes. Lets also say that there are two rowspans, one of them 80 rows long (rowspan="80") and the other 20 rows long (rowspan="20").

*The idea here is that the 80 rowspan "page-breaks" over 2 or more pages.

When princed, the resulting pdf is totally screwed up - producing unexpected results in several departments. In particular and most crucially:

1. THEAD fails to print at the top of every page.

2. The content of the rowspan="80" cell dissapears completely

3. Page breaking is just weird

Remove the rowspan altogether, and the problem disappears - thead prints on every page, content is all there, page breaking is good.

Just a note that we would prefer not to remove the rowspan from our table - it is semantically correct and it looks right too (in screen view).

Here are links to illustrate. The html is deliberately basic with no CSS. Adding CSS pagebreak rules seem to have no effect.

With rowspan - screwed:

Without rowspan - nice:
Thanks for the test case, we will investigate this issue.
Thanks Mike, this is mission critical for us.
It seems that this problem is caused by a limitation of Prince in handling table cells that span rows and are longer than an entire page. In this case, the entire table cell will be dropped, leading to the behaviour that you observed. Unfortunately it appears that we will not be able to fix this behaviour in Prince 6.0, and it's going to have to wait until the next major release when we hope to develop a new approach for splitting tables over multiple pages. Sorry for the inconvenience. :(

Update: It turns out that we might be able to do something about this for the next maintenance release of Prince 6.0, due for release early next month. :D
We have come up with a workaround in the meantime.

We got rid of the rowspans altogether and hid the appropriate cell borders to achieve the same visual effect. Then we put an absolutely positioned div inside the topmost cell so that the data doesn't make the table row stretch vertically.

It works visually, but it's semantically incorrect and it is possible for the div to grow beyond the table cell, which would not look good.

We will revert to rowspanning when you are ready.

Today we have released Prince 6.0 rev 4, with improved support for table cells that span many rows. Hopefully this should solve your problem! :)
First I am glad to see that Prince supports CMYK in JPG and TIFF images in the last revision! :)

But this issue on large rowspan on tables in more than one page is still there.

Do you know when this issue will be fixed?
Would you be able to post a link to a sample document, or email me ( so I can take a look?