Hi, I hope someone can give me a clue on how to make the schema name that a table exists in a configurable item during deployment of the EJB to the WAS server. I have two environments, a test environment and a live environment, and I don't want to have to re-map the RDB to EJB mappings to move from one environment to the other, just to change the schema name. Both environments have their own WAS v5 server with a DB2 (iSeries) datasource defined with CMP, but the datasource's default schema name is not being "respected", and the tables accessed by the EJBs are always the ones I used to do the RDB to EJB maping (the test environment). If anyone has any suggestions, I would sure appreciate it.
Hi- I don�t have a complete answer yet (as we are faced with the same issue) but I have learned that you can get around this seemingly hard-coded scenario by setting schema name in the xxx.schxmi file in your backend folder. You can set the database name in your xxx.dbxmi and connection info in xxx.rlconxmi. The generated schema names are simply names and nothing more at this point as I understand it although we have not tested a WAS deployment yet (using ANT) . I think there must be a WAS extension to ANT which will generate the deployment jars accordingly otherwise it makes little sense since the xmi files (connection info etc) is passed in the deployment jar and such a restriction would make CMP unusable. Let me know how you get along. Max
Joined: Jul 23, 2002
I got the answer for this in another forum. Here it is...
When you create a meet-in-the-middle mapping between the cmp bean and the table you can use the schema name 'NULLID'. Then WAS omits a schema name and the default schema name or the schema set by the property SQLID of the datasource is used.