Java开发网 |
注册 |
登录 |
帮助 |
搜索 |
排行榜 |
发帖统计
|
您没有登录 |
» Java开发网 » WebService/XML/JSON/SOAP/SOA
打印话题 寄给朋友 订阅主题 |
作者 | Re:axis问题,恳请热心人帮助!!!!!!!!!!! [Re:yanz03] |
yanz03
发贴: 6 积分: 0 |
于 2004-09-19 18:57
各位老大,我服务器端的代码是这样的,帮我看看吧,我真的很着急! import java.sql.Connection; import java.sql.DriverManager; import java.sql.ResultSet; import java.sql.SQLException; import java.sql.Statement; public class DBTest { private DBTest() { } public static Connection getConnection() { try { Class.forName("oracle.jdbc.driver.OracleDriver").newInstance(); return DriverManager.getConnection("jdbc:oracle:thinlocalhost:1521:yan", "hsapp","1"); } catch(Exception e) { e.printStackTrace(); return null; } } public static void close(Connection conn) { try { if(conn != null && !conn.isClosed()) { conn.close(); } }catch(SQLException e) { e.printStackTrace(); } } public ResultSet hello(String user_id) { ResultSet rs=null; try { Connection conn = DBTest.getConnection(); Statement st = conn.createStatement(); rs = st.executeQuery("select * from AWAKE_TEST where USERID='"+user_id+"'"); st.close(); conn.close(); }//end try catch(SQLException e) { e.printStackTrace(); }//end catch return rs; }//end DBTest } 菜鸟请教,基本程序调试不通,急急急急急急!!! |
话题树型展开 |
人气 | 标题 | 作者 | 字数 | 发贴时间 |
13489 | axis问题,恳请热心人帮助!!!!!!!!!!! | yanz03 | 282 | 2004-09-18 15:10 |
11111 | Re:axis问题,恳请热心人帮助!!!!!!!!!!! | sssmaan | 108 | 2004-09-19 10:22 |
12078 | Re:axis问题,恳请热心人帮助!!!!!!!!!!! | drewqi | 4 | 2004-12-16 00:59 |
11191 | Re:axis问题,恳请热心人帮助!!!!!!!!!!! | yanz03 | 104 | 2004-09-19 17:38 |
11210 | Re:axis问题,恳请热心人帮助!!!!!!!!!!! | yanz03 | 1128 | 2004-09-19 18:57 |
10988 | Re:axis问题,恳请热心人帮助!!!!!!!!!!! | nosleep | 253 | 2004-09-20 20:07 |
10968 | Re:axis问题,恳请热心人帮助!!!!!!!!!!! | BlurEyes | 31 | 2004-10-18 13:20 |
已读帖子 新的帖子 被删除的帖子 |
Powered by Jute Powerful Forum® Version Jute 1.5.6 Ent Copyright © 2002-2021 Cjsdn Team. All Righits Reserved. 闽ICP备05005120号-1 客服电话 18559299278 客服信箱 714923@qq.com 客服QQ 714923 |