SQLDocument is a content type which allows you to add/edit/display and display SQL - Querys.
SQLStatements in Plone.
It is based on the Zope Database Adapter.
You have the ability to make sub references to other SQLDocuments.
(Person --> Address). You can configure the view of your results.
- how many results per page
- which row should be displayed
- label of the rows
The greatest difference between the "old zope zsql way" to SQLDocument
is you do not need ZSQL-Methods and their "<dmtl-sql**>" statements.
Just simply type your sqlstatement in the SQL field.
select * from employees
If you need vars in your sqlstatement you can do it with this syntax
select * from employees where name = '%(NAME)s'
This will create a autogenerated input form with NAME as a text field for you.
If you want to export your results you have to install for:
pdf --> reportlab http://www.reportlab.org
xls --> pyXLWriter http://sourceforge.net/projects/pyxlwriter/
- easy to use
- auto generated input forms
- easy configuration of your linstings
- horizontal and vertical listing
- sort - navigation based on plone-batch
- subreferences to other sqldocuments
- export as pdf and xls (based on reportlab, pyXLWriter)
No stable release available yet.
If you are interested in getting the source code of this project, you can get it from the Code repository .