Tom Raj

Greenhorn
+ Follow
since Mar 03, 2005
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Tom Raj

Hi All,
I have a J2EE interview coming up.They are going to give me a problem and I've to come up with a solution. Does anyone know some sample design assignments. Please give me some tips on J2EE design. I confess that I'm not good at a design level!!. I've gone through the design patterns...

Thanks
Tom.
Thanks all, I figured out the issue. We were getting the connection outside the EJB. We moved the getConnection() method into the EJB and everything's working now.

Thanks
Tom.
Roger,
I'm using Websphere 5.1. and using UDB universal driver. I also think it could be something with the datasource. Do I have to create a reference to the datasource in the EJB deployment descriptor. I'm getting the connection outside the EJB and passing it to the EJB method.

Thanks
Tom
Hi,
I have an EJB method with transaction attribut 'Required'. We have multiple database updates in this method.To check whether the transaction handling is proper, we specifically threw an Exception after some table updates. This exception is caught and an EJBException is thrown later. Still the database changes are not rolling back. Please help me with this..

Could there be something at the DB level? We're using UDB 8.2

Thanks
Tom
Hi all,
I have a simple application. I'm trying to connect to my udb database thru the datasource defined on my local websphere server. The code is below. Initially I was getting a ClasscastException at the line 'ds = (DataSource) obj' . After several trials I included the database implementation jars in the websphere directory in the java app's classpath and it worked.

My question here is does my java application go to my server for getting the connection or after getting the datasource instance, the connection happens locally? To test this, I terminated my server after getting the datasource reference by lookup (my java app in debug mode) and then executed the ds.getconnection(). It worked and so I think the connection is obtained locally. So does this connection be in a pool??

Can somebody elaborate what is happening here??


Properties props = new Properties();
props.put(javax.naming.Context.INITIAL_CONTEXT_FACTORY,
DAOConstants.WS_INITIAL_CTX_FACTORY);
props.put(javax.naming.Context.PROVIDER_URL,"iiop://localhost:2809/");

DataSource ds = null;
Context context = new InitialContext(props);

Object obj = context.lookup("jdbc/CustDataSource");
ds = (DataSource) obj;
dBconn =ds.getConnection(DAOConstants.DB_USER_ID,DAOConstants.DB_USER_PWD);
Can somebody elaborate the difference between Static and Dynamic SQL. I think even if we have parameter markers in the SQL, it can be considered static. Does this has to do somehting with compilation/binding of the SQL??

If any body could give some examples that could be great..

Thx
Tom
Hi All,
I'm getting the error below

---- Begin backtrace for nested exception

com.ibm.db2.jcc.b.SqlException: The version of the IBM Universal JDBC driver in use is not licensed for connectivity to QDB2/SUN databases. To connect to this DB2 server, please obtain a licensed copy of the IBM DB2 Universal Driver for JDBC and SQLJ. An appropriate license file db2jcc_license_*.jar for this target platform must be installed to the application classpath. Connectivity to QDB2/SUN databases is enabled by any of the following license files: { db2jcc_license_cu.jar, db2jcc_license_cisuz.jar }

at java.lang.Throwable.<init>(Throwable.java)

at java.lang.Throwable.<init>(Throwable.java)

at java.sql.SQLException.<init>(SQLException.java:52)

at com.ibm.db2.jcc.b.SqlException.<init>(SqlException.java:96)

at com.ibm.db2.jcc.b.o.eb(o.java:3323)

at com.ibm.db2.jcc.b.o.a(o.java:3259)

at com.ibm.db2.jcc.c.b.a(b.java:578)

at com.ibm.db2.jcc.c.b.a(b.java:382)

at com.ibm.db2.jcc.c.b.<init>(b.java:326)


I looked into the directory and I can see the license files there.
Hi All,
I have a Java/J2EE interview coming up. Please provide me any resource which can help. Links or Books with interview questions.


Regards
Tom
Hi All,
How would I read messages from a queue set up on some server. Can I use jndi, and what are the properties I have to set for the initial context?

Thanx
Tom
Hi,
Anybody please suggest good books for SCEA..
There is no Pre-requisite for SCEA.