0

I am using a commercial PHP web application that stores information in a mysql database, and find myself needing to create some custom reports on that database information, ideally presented via the web with the ability of exporting the reports to PDF or some external format as well.

I could just slap together some PHP to query the DB and then show the results of SQL queries against that DB, but was hoping there may be a more intelligent framework I could employ to generate these reports faster and easier now as well as in the future. Codeigniter looks like it may be a good starting point, but I'm not in love with it. What do people use when they need to work with an existing SQL db info but dont want to roll it all from scratch?

edit - I know php/python/ruby enough to operate, but I'm rusty so starting from scratch will make the process longer than it probably needs to be. I'm looking to leverage quality frameworks if they exist to give me the best results in the longrun

S. Cobbs
  • 3
  • 2
  • Are we to assume you know PHP, Python, and Ruby and don't care which one you use for this? – agf Aug 03 '11 at 02:49
  • kinda duplicate of this: http://stackoverflow.com/questions/920889/open-source-php-reporting-tool – Ben Aug 03 '11 at 02:52
  • 1
    Have a look at Django. It has a dynamic admin interface (not code generation) and a built-in ORM that can take your existing schema and generate models from it automatically. From there you can create whatever views (controller actions) to query the data, present it in a template and export to PDF. – Brandon Taylor Aug 03 '11 at 02:55
  • Thanks Brandon, I've used Django and love it (the ORM is great!), but because I'm working with an existing DB I'm not sure how easily Django will operate... basically if I'd be fighting with it more than leveraging it. – S. Cobbs Aug 03 '11 at 02:57
  • two other possibilities that im looking at now are rlib and full blown BI with Pentaho. Thoughts? – S. Cobbs Aug 03 '11 at 03:11
  • @S. Cobbs Django is actually really great for integrating with legacy databases, check out [`manage.py inspectdb`](https://docs.djangoproject.com/en/dev/ref/django-admin/#inspectdb) which can automatically generate models from existing databases – Zach Kelling Aug 03 '11 at 03:13

1 Answers1

0

I would recommend Django, it has a management command that can help automatically generate models from an existing database, inspectdb. You could leverage that to quickly get going and start using Django's powerful ORM to build your reports.

Zach Kelling
  • 52,505
  • 13
  • 109
  • 108