Narendra Kamaraju

Greenhorn
+ Follow
since Jul 18, 2001
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
In last 30 days
0
Forums and Threads

Recent posts by Narendra Kamaraju

I'm encountering a strange problem when data between the XML tags contains literal ' " '.
Literal " ( " ) is prefixed by ' ( ' ) .
For example <Description>Box of height 4''</Description> is getting converted as <Description>Box of height 4' ''</Description>
This extra character is causing the failure of the program due to internal validation in code.
I'm using Sax parser for parsing my xml document.
Following is the code snippet.
public void characters(char[] cbuf, int start, int len)
{
Integer currElementType = (Integer) mCurrElementStack.peek();
StringBuffer strData = new StringBuffer().append(cbuf, start, len);
if(currElementType.intValue() == ATT)
{
mBuffer.append(strData.toString(), ATT);
}
}
Please let me know if I'm doing something incorrect or there is any workaround to overcome this restriction of the parser.
Thanks a lot for any help in this regard,
Regards,
Narendra.
[email protected]
Hi Peter,
How many levels of nesting you do recursively here.If it is just confined to two levels,please use the following logic to overcome the exception that you are getting.I hope you are using JDBC2.0 compliant drivers to support the multiple cursors for a single connection.


Please let me know if it is doesn't work.
Cheers,
Narendra.
[email protected]
Hi Rosalinde,
It looks like you are using the oracle drivers.
Try instantiating the oracle.jdbc.pool.OracleDataSource object rather than the javax.sql.DataSource.
I hope it should work.
Cheers,
Narendra.

Originally posted by David O'Meara:

Um, yeah. 'cos that helps
Generally we try to encourage people to discuss solutions on the boards so that others can benefit from the solutions too. If you find it's something that you want to work over privately, that's fine, but it ends up helping one person rather than, um, lots.



Hi David,
It was not intentional to post the query without any content.I have edited my post immediately to correct my mistake.
Sorry once again.
Regards,
Narendra
[email protected]

Hi Vikarm,
After creating the conneciton in the init() method,if you start invoking the servlet repeatedly over a period of time,it is going to open a cursor for each statement that you execute.Any database connection will have ceiling on maximum number of open cursors that it maintain for a single connection.Make sure that you close the statement and resultset once you are done with your work.
If you post your code here,I can tell you what exactly needs to be done.

Best of luck,
Cheers,
Narendra.
[ July 11, 2002: Message edited by: Narendra Kamaraju ]
Hi,
We have experienced the same problem with working on WAS3.5.3 or VA java's verison 3.5.3.
nested Marshall exception will be thrown only when communication/contact from the EJB to the container or vice_versa fails.
Only option to come out of this problem is restarting your appserver.You dont need to re-compile and re-deploy as the previous post suggested.
Hope this will clear doubt.
Regards,
Narendra.
Hi ,
I have to re-engineer existing VB front-end to JSP/Servlets.How do I create and process forms with multiple tabs in it.Any help in this is highly appreciated.
Thanks,
Narendra.
I'm getting an erro when I execute the following Strored Procedure with the parameters mentioned below.I'm running this from a session bean on UDB7.2 database.The query is...

CallabelStatement cst = con.prepareCall("XXXXXXXXXXX");
cst.setInt("v_uid", Integer.parseInt(uid));
cst.setInt("v_cd", myType);
cst.setString("v_id", myId);
cst.setTimestamp("v_network_dt", myDate);
cst.setString("v_reason", myReason);
cst.setShort("v_no", (short) myNumber);
cst.execute();
And the datatypes for the fields in the database are as below.
v_id VARCHAR(32),
v_cd INT,
v_no SMALLINT,
v_uid INT,
v_reason VARCHAR(255),
v_network_dt TIMESTAMP
I'm passing v_cd = 1,v_no = 0 and v_uid = 207 other fields are also passed properly.
When I execute this I get error message like this.....
SQL Exception - ErrorCode: -99999 ErrorMessage: [IBM][CLI Driver] CLI0111E Numeric value out of range. SQLSTATE=22003
what could be the reason?I'm passing the INT and SHORT fields withing its safe range only.
Great thanks for all those who contribute in solving my problem.
Regards,
Narendra.
Hi ,
I want to do jumpstart of some operations at the application start up time or new session start up time at global level of the application.I know this can be done by use of global.asa file in ASP's.How do I do this in servlets/JSP's.
Thanks in advance for the answers.
Cheers,
Narendra.
23 years ago
There is no way a webserver can send some custom error page when itself went down because of some problem.This can be achieved if you have another webserver installed beyond the firewall( AppServer resides within the firewall to make it more secure)to host all static HTML files.There you can configure the error page to throw the custom created error page incase if the default-server of the App Server is down.
I hope this will help.
Cheers,
Narendra.
23 years ago
Hi Rahul,

VAJ works with both UDB and DB2Connect.DB2Connect is basically a driver used to connect to Mainframes database.UDB is RDBMS version of DB2 on open systems.You said it's not working for you with UDB.Can you elaborate the error like ......???
Hi Sylvia,
I remember reading somewhere in the IBM red books that WAS(WebSphere Application Server) was suporting only UDB,Oracle and Instant DB.I'm not sure whether it has started supporting Sybase as well.So If WAS doesn't support,there is no way that Websphere Test Environment supports Sybase.Please check the documentation in IBM site.If you find some solution for the Sybase,please do let us know as well.
I hope this will help.
Narendra
23 years ago
If your upload form contains some form data also in addition to the files,best way is to use to use the mutipart request.There is a readymade code for handling file uploads with form data in the Oreilly site http://www.servlets.com/cos/index.html
Also your web server should support multipart/form-data MIME type.please check the current MIME types it has in the properties file and add this if required.
Good luck,
Narendra.
Have you included the JConnect driver classes (ZIP or jar file )either to the system classpath or to the project classpath in your VA Java.
Hope this will help you.
Good luck.
Narendra
JAD decompilation tool can be found at http://www.geocities.com/kpdus/jad.html.
Cheers,
Narendra.
23 years ago
Hi,
This happens when you have conflicting versions of JDBC classes available for the application.Run the usejdbc2.bat under ..\SQLLIB\java12 directory and add the db2java.zip to your classpath.Restart the serlvet engine to picl up the latest classpath.It will work.
Good luck,
Narendra Kamaraju