Hi

In one java bean , i retrieved data from the database and stored it in a
vector.
and i comparing for "" strings present in that vector and inserting elements
into it.

after doing this operation through jsp i am bringing on to the browser.

The problem is : it is giving internal server error
.......java.lang.outofmemory error.

any suggestions pls.

here is the code in the bean:


public Vector getdbURLAddress() throws Exception,SQLException
                {
                          String NA = "NA";
                          Vector r = new Vector();

                        //loop meant to send the query to the database
method for storing the data in the vector

                        try
                        {

                                 r = doExecute(query);
                         }
                         catch(SQLException se) { se.printStackTrace(); }

                        // checking the the vector for null or "" values.

                                        for(int i=0;i<r.size();i++)
                                        {

if((r.elementAt(i)==null)||(r.elementAt(i).equals("")))
                                                 {
                                                        try{

r.insertElementAt("NA",i);

}catch(ArrayIndexOutOfBoundsException aioe){ aioe.printStackTrace(); }

                                                 }
                                        }


                                return r;

                }


thanx in advance

regards
sharat

Sharath Babu, Konda.
GE Power Systems,
Schenectady,NY.

Ph: 518-385-2853(0)
      518-377-8024(R)
Home Page: www.geocities.com/sharat22

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
FAQs on JSP can be found at:
 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.html

Reply via email to