• 大小: 1.77MB
    文件类型: .rar
    金币: 1
    下载: 0 次
    发布日期: 2023-11-06
  • 语言: Java
  • 标签: jap  sql  

资源简介

用jsp和my sql制作的电子商务网上书店系统

资源截图

代码片段和文件信息

package myPk;
import java.sql.*;

public class Conn {
private String driverName=“sun.jdbc.odbc.JdbcOdbcDriver“;
private String dbUrl=“jdbc:odbc:bookShop“;
private String userName=““;
private String userPwd=““;
private Connection conn;
private Statement st;
private Pageable rs;

//连接数据库,执行语句,返回得到的记录项--用于查询
public void init(String sql) throws Exception
{
Class.forName(driverName);
conn=DriverManager.getConnection(dbUrl userNameuserPwd);
st=conn.createStatement(ResultSet.TYPE_SCROLL_INSENSITIVEResultSet.CONCUR_UPDATABLE);
rs=new PageableResultSet2(st.executeQuery(sql));
}

//判断记录欺罔是否为空,若为空则调用函数 init(sql)
public Pageable getRs(String sql) throws Exception
{
if(rs==null) 
{
init(sql);
}
return rs;
}

//执行 添加、更新、删除,无返回
public void exeUpd(String sql) throws Exception
{
Class.forName(driverName);
conn=DriverManager.getConnection(dbUrluserNameuserPwd);
st=conn.createStatement();
st.executeUpdate(sql);
}

//关闭 查询 连接
public void closeRs() throws Exception
{
rs.close();
st.close();
conn.close();
}

//关闭 添加、更新、删除 连接
public void closeNoRs() throws Exception
{
st.close();
conn.close();
}
}

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----

     文件        473  2007-01-14 11:01  fd\网上书店\bookShop\.classpath

     文件        853  2007-01-07 22:16  fd\网上书店\bookShop\.project

     文件        330  2007-01-07 22:16  fd\网上书店\bookShop\.settings\org.eclipse.jdt.core.prefs

     文件        217  2007-01-07 22:17  fd\网上书店\bookShop\.settings\org.eclipse.jst.common.project.facet.core.prefs

     文件        404  2007-01-07 22:17  fd\网上书店\bookShop\.settings\org.eclipse.wst.common.component

     文件        229  2007-01-07 22:17  fd\网上书店\bookShop\.settings\org.eclipse.wst.common.project.facet.core.xml

     文件       1976  2007-01-21 23:41  fd\网上书店\bookShop\build\classes\myPk\Conn.class

     文件       4350  2007-01-21 23:41  fd\网上书店\bookShop\build\classes\myPk\FileUploadBean.class

     文件       7705  2007-01-21 23:41  fd\网上书店\bookShop\build\classes\myPk\Md5.class

     文件        403  2007-01-21 23:41  fd\网上书店\bookShop\build\classes\myPk\Pageable.class

     文件      18053  2007-01-21 23:41  fd\网上书店\bookShop\build\classes\myPk\PageableResultSet2.class

     文件       1302  2007-01-18 14:10  fd\网上书店\bookShop\src\myPk\Conn.java

     文件       4703  2007-01-16 09:37  fd\网上书店\bookShop\src\myPk\FileUploadBean.java

     文件      14851  2007-01-13 11:12  fd\网上书店\bookShop\src\myPk\Md5.java

     文件        695  2007-01-07 22:19  fd\网上书店\bookShop\src\myPk\Pageable.java

     文件      18382  2007-01-07 22:20  fd\网上书店\bookShop\src\myPk\PageableResultSet2.java

     文件       7616  2007-01-20 01:33  fd\网上书店\bookShop\WebContent\admin-book-add.jsp

     文件       8043  2007-01-22 00:18  fd\网上书店\bookShop\WebContent\admin-book.jsp

     文件       1856  2007-01-21 22:21  fd\网上书店\bookShop\WebContent\admin-pwd.jsp

     文件       8968  2007-01-21 16:23  fd\网上书店\bookShop\WebContent\admin-user.jsp

     文件       4984  2007-01-21 23:55  fd\网上书店\bookShop\WebContent\blue.css

     文件      10920  2007-01-22 02:00  fd\网上书店\bookShop\WebContent\book-information.jsp

     文件       4739  2007-01-21 02:30  fd\网上书店\bookShop\WebContent\book-list.jsp

     文件       2087  2007-01-18 17:08  fd\网上书店\bookShop\WebContent\bottom.jsp

     文件        345  2007-01-15 22:19  fd\网上书店\bookShop\WebContent\clearSession.jsp

     文件     104166  2007-01-15 23:08  fd\网上书店\bookShop\WebContent\data\book.jpg

     文件       4096  2007-01-22 02:32  fd\网上书店\bookShop\WebContent\data\bookShop.ldb

     文件     626688  2007-01-22 02:27  fd\网上书店\bookShop\WebContent\data\bookShop.mdb

     文件      82406  2007-01-15 23:09  fd\网上书店\bookShop\WebContent\data\campaign.jpg

     文件      78682  2007-01-21 03:10  fd\网上书店\bookShop\WebContent\data\follow.jpg

............此处省略103个文件信息

评论

共有 条评论