Icon View Thread

The following is the text of the current message along with any replies.
Messages 1 to 3 of 3 total
Thread How many databases components
Mon, Apr 19 2010 4:52 AMPermanent Link

Hershcu Sorin

Hello

The method I addopt for my application is creating one datamodule with the
engine and sesssion components. This dm is created auto with the application
and
here I set all the configurations.
Additional the app have several others datamodule that are created during
the run time.
On each one I have a tedbdatabase component connected to the engine and
session on the main datamodule.

Is this a good desing or should I use instead a single tedbdatabase on the
main datamodule?
Are there any pros and cons to each design?

Thanks
Sorin

Mon, Apr 19 2010 5:17 AMPermanent Link

Roy Lambert

NLH Associates

Team Elevate Team Elevate

Sorin


I tend to use 1 TEDBDatabase for each physical database. It goes on a datamodule which is created before the main form. This datamodule also contains the session for the app.

Tables may be on datamodules or forms, generally the latter.

Tables, queries etc (unless they are in threads) all point to the database on the datamodule.


Roy Lambert
Mon, Apr 19 2010 6:45 AMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Sorin,

<< Is this a good desing or should I use instead a single tedbdatabase on
the main datamodule?  Are there any pros and cons to each design? >>

There's really no downside to designing the data modules like that, apart
from possible design-time errors if the main data module isn't open when you
try to open the "sub" data modules.  You should usually stick with what
works for your application.

For our internal systems here, we use two data modules - one for the
system-wide tables (utility tables for web server, mail server, etc.), and
one for the company-specific data (customer data, etc.).

--
Tim Young
Elevate Software
www.elevatesoft.com
Image