db-torque-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Alexandru Dovlecel" <alexandru.dovle...@siemens.com>
Subject schema.xml and databaseName
Date Wed, 21 Apr 2004 12:11:55 GMT
Hi all,

I have a problem and I don't know what to do. I have set in my x-schema.xml
the databaseName='x'.

But in my runtime configuration file I have the database renamed from 'x' to
'myx'. When trying to run the program I get strange NullPointerException.
Why? (e.g. myobj.save( "myx" ) ;

1) If I change the runtime configuration file and I have the database name
as 'x', all works fine. (also changing the myobj.save( "myx" ) to
myobj.save( "x" )

2) If I change the schema file with databaseName="myx" and I regenerate the
files with ant, it works fine.

So... this is really strange. It should not happen, because in this case, I
always have to match the name in the schema.xml file with the name in the
runtime configuration file. So if I need a different runtime config DBName,
then I have to recreate the files??? C'mon... am I doing something wrong???

And also, I can't reuse the generated classes to access two databases, even
though they have exactly the same structure, because they will have two
DBNames in the runtime config file. This is quite a nasty problem (IMHO).

Can somebody tell me how to overcome this situation?

10q
Alex


---------------------------------------------------------------------
To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
For additional commands, e-mail: torque-user-help@db.apache.org


Mime
View raw message