You are viewing a plain text version of this content. The canonical link for it is here.
Posted to torque-user@db.apache.org by Marc Dugger <ma...@socotech.com> on 2003/12/13 00:22:44 UTC
how best to "flatten" database
My database has 62 tables in it and the user wants to be able to dynamically
select (via web app) individual data elements across tables for export to a
spreadsheet. The record count could be anywhere from 100 to upper 1000's.
Since I'm using Torque for persistence, I started using the OM to traverse
the data, but started fretting about the potential number of database hits.
I've also considered straight SQL to do a broad select (JOIN everything),
but am not comfortable with dynamically constructing such a mammoth
statement. Unfortunately, a database tool is not an option...it must be
from within the context of the application. Any gurus out there with
advice/links to articles? Thanks in advance.
---------------------------------------------------------------------
To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
For additional commands, e-mail: torque-user-help@db.apache.org
RE: how best to "flatten" database
Posted by Marc Dugger <ma...@socotech.com>.
Sorry, I forgot to mention my database: MySQL. Views aren't available
until 5.x.
> -----Original Message-----
> From: Ramesh Sabeti [mailto:rs@reazon.com]
> Sent: Friday, December 12, 2003 6:43 PM
> To: 'Apache Torque Users List'; marc@socotech.com
> Subject: RE: how best to "flatten" database
>
>
> How about using a "view"?
>
> Ramesh.
>
> > -----Original Message-----
> > From: Marc Dugger [mailto:marc@socotech.com]
> > Sent: Friday, December 12, 2003 3:23 PM
> > To: torque-user@db.apache.org
> > Subject: how best to "flatten" database
> >
> > My database has 62 tables in it and the user wants to be able to
> > dynamically
> > select (via web app) individual data elements across tables for export
> to
> > a
> > spreadsheet. The record count could be anywhere from 100 to upper
> 1000's.
> > Since I'm using Torque for persistence, I started using the OM to
> traverse
> > the data, but started fretting about the potential number of database
> > hits.
> > I've also considered straight SQL to do a broad select (JOIN
> everything),
> > but am not comfortable with dynamically constructing such a mammoth
> > statement. Unfortunately, a database tool is not an option...it must
> be
> > from within the context of the application. Any gurus out there with
> > advice/links to articles? Thanks in advance.
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
> > For additional commands, e-mail: torque-user-help@db.apache.org
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
> For additional commands, e-mail: torque-user-help@db.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
For additional commands, e-mail: torque-user-help@db.apache.org
RE: how best to "flatten" database
Posted by Ramesh Sabeti <rs...@reazon.com>.
How about using a "view"?
Ramesh.
> -----Original Message-----
> From: Marc Dugger [mailto:marc@socotech.com]
> Sent: Friday, December 12, 2003 3:23 PM
> To: torque-user@db.apache.org
> Subject: how best to "flatten" database
>
> My database has 62 tables in it and the user wants to be able to
> dynamically
> select (via web app) individual data elements across tables for export
to
> a
> spreadsheet. The record count could be anywhere from 100 to upper
1000's.
> Since I'm using Torque for persistence, I started using the OM to
traverse
> the data, but started fretting about the potential number of database
> hits.
> I've also considered straight SQL to do a broad select (JOIN
everything),
> but am not comfortable with dynamically constructing such a mammoth
> statement. Unfortunately, a database tool is not an option...it must
be
> from within the context of the application. Any gurus out there with
> advice/links to articles? Thanks in advance.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
> For additional commands, e-mail: torque-user-help@db.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
For additional commands, e-mail: torque-user-help@db.apache.org