This is really baffling...

I have a service that queries a DB for data. The service can
be configured to query from any DB; the XML schema file does
not provide a DB name.

I configured two databases to be identical in TR.props: default
and gonzo:


database.default.driver=org.gjt.mm.mysql.Driver
database.default.url=jdbc:mysql://localhost:3306/turbine
database.default.username=turbine
database.default.password=turbine

database.gonzo.driver=org.gjt.mm.mysql.Driver
database.gonzo.url=jdbc:mysql://localhost:3306/turbine
database.gonzo.username=turbine
database.gonzo.password=turbine


If I configure my service to use DB default, everything works.

If I configure it to use DB gonzo, some queries work and some
don't. In particular, any queries that did addAscendingOrderByColumn()
throw an exception in BasePeer.java:1039, which is:


            for (int i=0; i<orderBy.size(); i++)
            {
/* HERE */      String orderByColumn = orderBy.get(i);
                String table =
orderByColumn.substring(0,orderByColumn.indexOf('.') );


Again, things work PERFECTLY when accessing the SAME data via the
DB called default, and fail when accessing the data via gonzo.

Other than saying "you should NEVER call a DB 'gonzo'", anybody has
any ideas why this could be happening?


-- 
Gonzalo A. Diethelm
[EMAIL PROTECTED]

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to