I'd like to get some ideas on best object design for using multiple dbs
e.e. Oracle and Sybase. In the past I've only done some re-writing of
apps to point at either DB and just did some and then use a case
statement, looked at the JDBC driver class name. If it had the word
Sybase in it I did one thing and if it had Oracle in it I did another.
When I start the app I use parameters which tell it the URL for the DB
and which driver to use.
I could use one DB object for each database but I think that would get
unweildy with at lesat 2 methods for each object with whose data is
inthe db, e.g. customer, invoice, line item.
I could write one object for each database so I'd have a sybaseCustomer,
oracleCutomer etc.
Then were do you make the decision? Do I use and object factory that
knows about which of the two to use?
ObjectFActory.getObject("Customer");
Just looking for advice fromthose that have been down the road before.
Thank
jw