Hi Stacy,
 
I am not answering your question - just have a look at ReportLab's toolkit before you write your own. It seems great to me. We use their stuff from Python and find it excellent. They also have plugins for CF for reporting. http://www.reportlab.com/
 
Sincerely
Hardy
 
----- Original Message -----
Sent: Saturday, October 04, 2003 3:35 AM
Subject: [CFCDev] Modeling a Reporting Engine

I�ve been working on a reporting engine for in-house (since we�re turfing Crystal finally). I haven�t had trouble modeling my supporting services/components (i.e. CSV output utility etc) but I�m having a helluva time trying to figure out how to model the most important part, the reports! LoL

 

First time around I�m trying to keep it simple�essentially have a generic �Report� object which then gets extended for each new report we create. Each report is just a sql query with optional search parameters (the reports �properties�)�meaning the statement is built using a bunch of cfif statements.

 

Since I�m stuck trying to bang out the model, I thought maybe it�d be easier to imagine how I�d actually want to leverage this engine in the scope of an application:

 

<cfset reportManager = CreateObject(�component�,�ReportManager�).init()>

<cfset report = reportManager.generate( reportType, attributeCollection, persistanceLevel )>

 

But I�m trying to avoid a situation where every time we need to add a new report, we have to make changes to the manager AND extend the Report object with another subtype. I�d like to be able to just drop in the new subtype and have it work straight away.

 

My first thought was to have the manager evaluate the reportType attribute and attempt to invoke a CFC of the same name. This CFC would extend the Report object and have its own �query� method for its specific DB work.

 

Am I way off here? (or making any sense for that matter ;) � I haven�t even begun to think about adding a persistence mechanism for recordsets used in a display. (cached so user can browse quickly without re-querying)

 

Any pointers appreciated!

 

Stace

 



AVIS IMPORTANT:
-------------------------------
Les informations contenues dans le present document et ses pieces jointes sont strictement confidentielles et reservees a l'usage de la (des) personne(s) a qui il est adresse. Si vous n'etes pas le destinataire, soyez avise que toute divulgation, distribution, copie, ou autre utilisation de ces informations est strictement prohibee. Si vous avez recu ce document par erreur, veuillez s'il vous plait communiquer immediatement avec l'expediteur et detruire ce document sans en faire de copie sous quelque forme.

WARNING:
-------------------------------
The information contained in this document and attachments is confidential and intended only for the person(s) named above. If you are not the intended recipient you are hereby notified that any disclosure, copying, distribution, or any other use of the information is strictly prohibited. If you have received this document by mistake, please notify the sender immediately and destroy this document and attachments without making any copy of any kind.

Reply via email to