on 04-28-2008 2:36 PM
Hi,
I am using BI SDK to connect from Web Dynpro DC to BW system.
I have a external library created, BIWrapper.jar that performs the BW connection.
I have created a Web Dynpro DC project and uses the BIWrapper.jar as external library to perform the BW connection. Once I deploy and activate the Web Dynpro DC in NWDI, it gets deploy to the WAS server.
I am running into problems in the code of BIWrapper.jar whenever it is performing a BW connection.
private void connect()
{
try
{
Context initctx = new InitialContext();
IConnectionFactory cf=null;
try
{
cf = (IConnectionFactory)initctx.lookup("deployedAdapters/SDK_XMLA/shareable/SDK_XMLA");
}
catch(Exception e_jndi)
{
}
IConnectionSpec cs = cf.getConnectionSpec();
connection = (IBIConnection)cf.getConnectionEx(cs);
olap = connection.getOlap();
if(olap != null)
isConnected = true;
}
catch(Exception e)
{
e.printStackTrace();
if(e instanceof IBaseException)
* addError("Error in BITable connect method: " + ((IBaseException)e).getNestedLocalizedMessage());*
else
* addError("Error in BITable connect method: " + e.getMessage());*
}
}
The error is java.lang.nullpointerexception when it execute the code at
IConnectionSpec cs = cf.getConnectionSpec();
All the BI SDK settings have been correctly setup in Visual Admin.
Any help would be useful...
Thanks.
-mike
Edited by: Mike Lee on Apr 28, 2008 9:36 AM
Edited by: Mike Lee on Apr 28, 2008 9:39 AM
Hi,
It may be because of following two reasons.
1. Your datasource is not running currently. If so go to nwa and start it.
2. your string "deployedAdapters/SDK_XMLA/shareable/SDK_XMLA" for lookup does not match with that of the datasource or alias you are using.
Regards,
Srinivasan Subbiah
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
I have checked that the datasource is running and the path
"deployedAdapters/SDK_XMLA/shareable/SDK_XMLA" is correct.
Just did two experiments :
If I build and deploy via NWDI to a WAS server (ABAP+JAVA), it did not work.
If I build and deploy via my NWDS to a WAS server (JAVA), it WORKS!
This is really strange.
any help would be appreciated.
thanks.
mike
Hi Mike
May be the IConnectionFactory object is null,check out your look up string may be some thing is not matching in your look up string.
Regards
kalyan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
84 | |
10 | |
10 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.