| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 693 人关注过本帖
标题:[求助]求救:请各位jsp高手帮忙
只看楼主 加入收藏
foreverzxy
Rank: 1
等 级:新手上路
帖 子:3
专家分:0
注 册:2005-9-2
收藏
 问题点数:0 回复次数:3 
[求助]求救:请各位jsp高手帮忙

写了一个连接到数据库读取数据的jsp文件,但是在tomcat下运行的时候,出现了下面的错误:

HTTP Status 500 -


type Exception report

message

description The server encountered an internal error () that prevented it from fulfilling this request.

exception

javax.servlet.ServletException
	org.apache.jasper.runtime.PageContextImpl.doHandlePageException(PageContextImpl.java:845)
	org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:778)
	org.apache.jsp.connect_jsp._jspService(connect_jsp.java:77)
	org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:94)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
	org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:324)
	org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)
	org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:802)

root cause

java.lang.OutOfMemoryError

note The full stack trace of the root cause is available in the Apache Tomcat/5.0.29 logs. 部分代码是这样的: Connection conn= DriverManager.getConnection(url,user,password); Statement stmt=conn.createStatement(); String sql = new String(); sql="select signal_name from repdata1_pri where rec_id like'200507172000%'"; ResultSet rs=stmt.executeQuery(sql); while(rs.next()) { temp=rs.getString("signal_name"); out.println(temp); } rs.close(); stmt.close(); conn.close(); 请高手们帮我看看这到底是怎么回事啊?

搜索更多相关主题的帖子: jsp 
2005-09-22 15:37
bestlife
Rank: 1
等 级:新手上路
帖 子:484
专家分:0
注 册:2005-7-8
收藏
得分:0 
在TOMCAT启动文件catalina.bat里面"JAVA_OPTS='-Xms256m -Xmx300m'"
    -Xms是最小内存容量,-Xmx是最大内存容量。
试试把内存容量改大点

[此贴子已经被作者于2005-9-22 16:30:11编辑过]



修炼修炼再修炼 成长成长再成长
2005-09-22 15:59
叶天兵
Rank: 1
等 级:新手上路
帖 子:24
专家分:0
注 册:2005-8-20
收藏
得分:0 
网上复制的代码有时候就是这样!~

/bbs/UploadFile/2005-9/200592122155895112.jpg" border="0" onload="if(this.width>screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.alt='Click here to open new window\nCTRL+Mouse wheel to zoom in/out';}" onmouseover="if(this.width>screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.style.cursor='hand'; this.alt='Click here to open new window\nCTRL+Mouse wheel to zoom in/out';}" onclick="if(!this.resized) {return true;} else {window.open('http://www./bbs/UploadFile/2005-9/200592122155895112.jpg');}" onmousewheel="return imgzoom(this);" alt="" />
2005-09-22 18:29
zishan
Rank: 1
等 级:新手上路
帖 子:37
专家分:0
注 册:2005-8-6
收藏
得分:0 
建议你用javabean实现数据库连接

2005-09-25 09:41
快速回复:[求助]求救:请各位jsp高手帮忙
数据加载中...
 
   



关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.018163 second(s), 8 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved