Would anyone know what I could possibly be doing to bring down the web server just by doing a database lookup? I�m using a jsp page that returns the result set from a database and I�m consistently crashing our web server (orion).
I�m using dreamweaver mx to pump out the jsp code but I doubt that dreamweaver is putting out such bad code that it would be crashing the server?!? Or maybe it is....
I mean, the code would have to be doing something pretty bad to actually bring down a server, right?
Are you using a JDNC driver with native code (e.g. the JDBC-ODBC driver)? If so, it's not at all unlikely that the code generated by Dreamweaver MX causes the web server to crash. Simply doing things like working with multiple ResultSets in a manner that's not supported by the JDBC spec may cause serious enough errors in the native code that brings down the server. A pure Java JDBC driver reports the error instead. The JDBC-ODBC driver is also infamous for being buggy and is not intended for production use. If you use it, I suggest you find another driver. Most database vendors offer free pure Java drivers, and there are lots of commercial drivers available as well.
I also recommend that you use the JSP Standard Tag Libraries (JSTL) database actions instead of letting Dreamweaver MX generate JDBC code in your pages. It minimizes the risk for this type of problems and keep the JSP pages easier to maintain. If you're a Java programmer, an even better approach is to do all database stuff in a servlet instead and forward to a JSP page that displays the result.
Hans -- Hans Bergsten <[EMAIL PROTECTED]> Gefion Software <http://www.gefionsoftware.com/> Author of O'Reilly's "JavaServer Pages", covering JSP 1.2 and JSTL 1.0 Details at <http://TheJSPBook.com/>
=========================================================================== To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST". For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST".
Some relevant archives, FAQs and Forums on JSPs can be found at:
http://java.sun.com/products/jsp http://archives.java.sun.com/jsp-interest.html http://forums.java.sun.com http://www.jspinsider.com
