[reportlab-users] Database reporting
andy at reportlab.com
Sun Jun 2 08:44:07 EDT 2013
Using pure reportlab, I would say the following:
1. We still cannot have a single table cell be larger than one page.
The code is just too hard for us to write in any reasonable timeframe,
as it has to be compatible with all the other things you can already
do in a table (row and column spanning, auto sizing and so on...)
2. Trying to make a report out of 'one giant table' is nuts and leads
to ridiculously complicated styling. The way to go is to pick or
design your column widths, and generate distinct 'one row' or 'few
row' tables with no space between for each distinct type of band.
3. Our own framework also deliberately doesn't know about numbers or
table contents. So any kind of totalling or counting must be done in
your own code; and since your own code doesn't usually know what page
you are on, it's quite tricky to do totals of elements on the current
I'm not familiar with Geraldo, Dabo etc as we don't do much database
reporting in house, but there is definitely a scope for a good higher
level solution here and it would be great to hear feedback about them
on the list...
On 2 June 2013 07:31, Werner F. Bruhin <werner.bruhin at free.fr> wrote:
> Hi Paul,
> On 02/06/2013 05:54, Paul McNett wrote:
>> On 6/1/13 9:49 AM, Werner F. Bruhin wrote:
>>> It seems to have a similar issue I have with PythonReports that an
>>> element (in
>>> Geraldo a "child_bands" containing a ReportBand) does not span across
>>> multiple pages.
>> Dabo's report writer handles long text spanning to multiple pages. It also
>> has a
>> designer that gets you most if not all of the way there.
> I am aware of it but had the impression that it expects a Dabo bisobj, could
> I use it with using SQLAlchemy to access my database? I.e. feed it a
> SQLAlchemy query and access relations to get at columns?
> result = session.query(db.Winerack)
> for r in result:
> print r.name
> for u in r.wineracku:
> print u.description
> for b in u.winerackb:
> print b.description, b.binno
> for i in b.winerackit:
> print i.subbinno
> if i.bottag:
> print i.bottag.cellarbook.drinkinfo.name
> the "for" loops would be groups and the last one would be the detail level
> which might need one or more lines. In some of the reports the "more lines"
> would be large text blob column which is the one which might need to span
> over multiple pages.
> reportlab-users mailing list
> reportlab-users at lists2.reportlab.com
ReportLab Europe Ltd.
Thornton House, Thornton Road, Wimbledon, London SW19 4NG, UK
More information about the reportlab-users