A Dijous, 10 de setembre de 2009, [email protected] va escriure:
> Although OpenERP has the Open Office based report writer, I think its main
>  usefulness is for company documents like invoices etc and simple reports.
>  Also the cube functionality is wonderful, but for serious report
>  generation a 3rd party tool is required.
> 
> Has anyone had any experience using 3rd party report tools (eg Crystal
>  Reports, Jasper reports, LogiXML...) with the OpenErp Postgres database?
>  After looking at the DB schema, I think it may be possible to use 3rd
>  party tools to generate good sales analysis reports (after doing a
>  substantial SQL join), but some reports would be impossible due to the
>  nature of the ORM mapping, eg nested hierarchies such as customer or stock
>  item product groups etc. However, for sales analysis reporting I think it
>  would be possible.

At NaN, we've created a jasper_reports module (available in koo's repository) 
[1] for OpenERP that lets you create Jasper Reports perfectly integrated. 
Reports can be feeded with data from the database, from data provided with 
python or by browsing the models (more info in our blog [2]). Output can be 
created in PDF, ODT, CSV, TXT, ODS, XLS...

Regarding nested hierarchies, they are not impossible to handle if you're 
using PostgreSQL 8.4 thanks to it's support for CTE (Commont Table 
Expressions), which allows recursive queries [3].

What I'd encourage for reports, though, is the combination of SQL and browsing 
models. I think the most powerful way of handling complex reports is to create 
a new "virtual" model in OpenERP which executes a query (there are already 
some examples in bazaar). This query can be as complex as you need (including 
the use of CTE's), but instead o returning ALL product fields you'll need in 
the report (for example), you return a many2one to the product. Then you can 
use the browsing method so you'll have access to all information of the 
product including its relations with other models. Even more, you won't have 
to worry about the language of the product name as browsing will help you with 
this (again, you may take a look at the blog).

[1] https://code.launchpad.net/~openobject-client-kde/openobject-client-
kde/5.0
[2] http://albert-nan.blogspot.com/search/label/jasperreports
[3] http://www.postgresql.org/docs/8.4/static/sql-select.html#SQL-WITH

> 
> Any comments, previous experience, suggestions or "gotcha's" would be
>  appreciated.
> 
> 
> 
> 
> -------------------- m2f --------------------
> 
> --
> http://www.openobject.com/forum/viewtopic.php?p=43198#43198
> 
> -------------------- m2f --------------------
> 
> 
> _______________________________________________
> Tinyerp-users mailing list
> http://tiny.be/mailman2/listinfo/tinyerp-users
> 


-- 
Albert Cervera i Areny
http://www.NaN-tic.com
Mòbil: +34 669 40 40 18
_______________________________________________
Tinyerp-users mailing list
http://tiny.be/mailman2/listinfo/tinyerp-users

Reply via email to