The 'null' appears as a String in Weblogic 8.1?

Posted on 2004-08-12
Last Modified: 2013-12-10
We are having a small problem with out Servlets after we started porting all Projects to Weblogic 8.1 from 5.1... The below mentioned servlet code-segment works well in both 5.1 & 8.1 , except for 1 small diference... The 'null' appears as a String in Weblogic 8.1, and as ' ' in 5.1, We have developed many thousands of servlets around this concept. Is there any way we can display that annoying 'null' string as ' ' in Weblogic 8.1 (just like in the Weblogic 5.1 and previous versions)?... please help. IO Believe that the problem lies in the Servlet API - Since this same this is present in the Tomcat 5 and JBoss as well,

ServletOutputStream out=null;

    String abc = null;
    out = res.getOutputStream();
}catch(Exception er11){ }

Question by:ErandikaUmal
LVL 23

Accepted Solution

rama_krishna580 earned 500 total points
ID: 11803115

we also have the same problem in our application(s)... I think you have only one way to do this...

After variable "abc" validated, then check for abc value...

if (abc == null) abc = "";

thats all you can do it, this is new change in Weblogic 8.1.

i hope it may help you..



Expert Comment

ID: 11839852
Hi R.K

shouldnt this be , as we need to compare the null string and not the null object

if (abc.equals("null" ) abc = "";


Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

-Xmx and -Xms are the two JVM options often used to tune JVM heap size.   Here are some common mistakes made when using them:   Assume BigApp is a java class file for the below examples. 1.         Missing m, M, g or G at the end …
Verbose logging is used to diagnose garbage collector problems. By default, -verbose:gc output is written to either native_stderr.log or native_stdout.log.   It is also possible to redirect the logs to a user-specified file. This article will de…
A short film showing how OnPage and Connectwise integration works.
I designed this idea while studying technology in the classroom.  This is a semester long project.  Students are asked to take photographs on a specific topic which they find meaningful, it can be a place or situation such as travel or homelessness.…

914 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

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now