[reportlab-users] Use With SQLite3

Paul McNett p at ulmcnett.com
Tue Feb 13 20:44:57 EST 2007


Rich Shepard wrote:

> On Tue, 13 Feb 2007, Paul McNett wrote:

>

>> Rich, FWIW Dabo is fairly modular, and in particular the report writer

>> doesn't need to feed from a Dabo cursor. You can just feed it a tuple of

>> dicts, where each element in the tuple is a record, and each item in the

>> dict is a field, the key being the field name and the value being the

>> field value.

>

> How kewel!! When I 'select from ...' with pysqlite2 I get a list of

> tuples. Your tuple of dicts is interesting, and I think it's elegant.


You can configure sqlite to return DictCursors by default. See:
http://www.initd.org/tracker/pysqlite/wiki/PysqliteFactories

Otherwise, you can run the conversion manually after the fact.


--
pkm ~ http://paulmcnett.com



More information about the reportlab-users mailing list