Solved

Configuring JNDI on Websphere for DB2

Posted on 2009-05-18
6
2,473 Views
Last Modified: 2013-12-11
Hi,
In our project we have different schemas in DB2. We want to configure JNDI in websphere in such a way that each JNDI points to separate database schema. But in websphere configuration we cannot specify the schema name. All that we specify is the userid. And in DB2 the default schema name is the userid. Thus the JNDI always points to the schema with name same as userid. How can i make JNDI to point to a different schema?
0
Comment
Question by:cuttieveenz
  • 2
  • 2
6 Comments
 
LVL 37

Accepted Solution

by:
momi_sabag earned 168 total points
ID: 24415863
are you sure?
if i remember correctly, you can specify a value for current schema when you configure websphere
0
 
LVL 45

Assisted Solution

by:Kdo
Kdo earned 332 total points
ID: 24415902
Hi cuttie,

In database.properties, just set the schema name:

  DB2DAOFactory.database.schema.name=schemaABC



Kent
0
 

Author Comment

by:cuttieveenz
ID: 24415947
Where is this properties file? Also how does the JNDI map to the schema name in this file?
0
 

Author Comment

by:cuttieveenz
ID: 24416045
where is this properties file? and how does the JNDI map to the schema name in this file?bcoz in JNDI configuration only the useid,pwd is specified. also in the datasource configuration only the server name, DB name, port, driver type is mentioned.
0
 
LVL 45

Assisted Solution

by:Kdo
Kdo earned 332 total points
ID: 24416118
Hi cuttie,

This is probably more than you want to read, but there's a very good description of the JNDI options here:

  http://java.sun.com/products/jndi/tutorial/beyond/env/source.html

The path to the file is:

  $JAVA_HOME/lib/jndi.properties


Good Luck,
Kent


0

Featured Post

Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
micro services vs rest web services 16 107
micro services spring boot application error 3 197
iterator/ListIterator approach 17 27
Modify select statment 10 31
Configure Web Service (server application) I. Configure security for Web Services methods First, we need to protect Session bean which implements the service: 1. Open EJB deployment descriptor (ejb-jar.xml) in the EJB project that contains you…
Recursive SQL in UDB/LUW (it really isn't that hard to do) Recursive SQL is most often used to convert columns to rows or rows to columns.  A previous article described the process of converting rows to columns.  This article will build off of th…
The viewer will learn how to implement Singleton Design Pattern in Java.
This tutorial covers a practical example of lazy loading technique and early loading technique in a Singleton Design Pattern.

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question