Re: One app, multiple databases?
Re: One app, multiple databases?
- Subject: Re: One app, multiple databases?
- From: Sacha Mallais <email@hidden>
- Date: Wed, 15 Jun 2005 21:30:27 -0700
On Jun 15, 2005, at 5:20 PM, Rams wrote:
On Jun 15, 2005, at 4:24 PM, Sacha Mallais wrote:
On Jun 15, 2005, at 12:55 PM, Rams wrote:
Is it possible to create one WO app and have it access different
databases based on the client? For instance, I would like to
create a point of sale (POS) app. Different clients have
different inventory requirements and would obviously like their
own database. Someone selling stationary needs different
inventory information than someone selling pets, automobiles,
clothing, or whatever.
The difficulty is having multiple databases' tables map to the
entities in a single model. WO don't play dat.
So if I understand correctly, I cannot programmatically change the
database address of my EOModel within a WO app. It must be done
with EOModeler or XCode.
Not exactly: you can, but once you've connected, you can no longer
(safely) change it.
Ideally, I'd like the client to be able to dictate what inventory
information they would like to store and then be assigned their
own database for inventory without much intervention on my part.
Is there any way to do this with WO?
The catch is "assigned their own database". The rest is easily
possible within a single application.
If you must force WO to dynamically create databases and EOModels
that models those databases, then you might look at dynamically
creating EOModels and EOEntities (perhaps subentities of existing,
abstract entities).
So I can dynamically generate a database table within the app? Any
pointers on where to start? (sample code, examples, reference
material or API docs)
Nothing in WO helps or hinders creating databases. You _may_ be able
to get WO to generate the SQL to create new tables, but that stuff is
private API, so I'm not familiar with it. Your best bet for example
code is probably to find some JDBC stuff.
sacha
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden