实验室资产管理系统查询模块

dstandardizationofsafetyproduction,andstrivetoachieve\nsicallysafe\safetysectionandisaunitofsecurityofficersresponsibleforminesafetydutiesandsupervisetheimplementationofthefollow-upto,andimplementationofthesystem,prosecution.PartImanagementsystems...Youcanusebrazierswhen,2--3metersfromthegroundandputthefireoutbeforethework,confirmthenofirebeforetheycanleave;Highway11non-staffinthemarginwithin50m,radiusoftheexcavationwork,andworkingwithin6metresoftheedgeandstayundertheumbrellaheading;12,blastingintothepitpersonnelmustfollowtheshootingguard'scommand,hidetosafety;13non-miningvehicles(includingbicycles,animal-drawnvehicle,motorvehicles,etc)willbebannedfromenteringthepitsandotherproductionareaonpainofheavyfines,resultinginaccidentstobeinvestigatedforresponsibility;14shootingthefollowingmechanicalsafetydistancesasfollows:categorynamemechanicalcannonsshallowholesandpopshootingexposedblastingunits:metersdiggingmachinerigcargunpowderotherequipment-pitequipment,especiallyanelectricalswitchandavarietyofsafetydevices,inadditiontospecifyingtheuseofresponsiblepersonnel,bananytouchingofotherpersonnel;16foundthatpowerlinesorcablesbreakinggroundbeforewithoutascertainingwhetherthecharged,prohibitsanyonefromtouching,andshouldleave5metersaway,andimmediatelynotifythepersonchecking;17withouttheleadership'sconsent,arenotallowedtotakethestrippedtrucks,watertankers,oiltankers,asaresultofthecau 实验室资产管理系统

—查询模块

一、 开发环境

MyEclipse 8.5 + Mysql 5.09 + tomcat 6.0

MyEclipse企业级工作平台(MyEclipse Enterprise Workbench ,简称MyEclipse)是对 Eclipse IDE的扩展,利用它我们可以在数据库和JavaEE的开发、发布,以及应用程序服务器的整合方面极大的提高工作效率。它是功能丰富的JavaEE集成开 发环境,包括了完备的编码、调试、测试和发布功能,完整支持HTML, Struts, JSF, CSS, Javascript, SQL, Hibernate。

MySQL是一个小型关系型数据库管理系统,目前 MySQL被广泛地应用在Internet上的中小型网站中。由于其体积小、速度快、总体拥有成本低,尤其是开放源码这一特点,许多中小型网站为了降低网 站总体拥有成本而选择了MySQL作为网站数据库。

Tomcat 是一个小型的轻量级应用服务器, 在中小型系统和并发访问用户不是很多的场合下被普遍使用,是开发和调试JSP 程序的首选。对于一个初学者来说,可以这样认为,当在一台机器上配置好Apache 服务器,可利用它响应对HTML 页面的访问请求。实际上Tomcat 部分是Apache 服务器的扩展,但它是独立运行的,所以当你运行tomcat 时,它实际上作为一个与Apache 独立的进程单独运行的。

Apache 为HTML页面服务,而Tomcat 实际上运行JSP 页面和Servlet。另外,Tomcat和IIS、Apache等Web服务器一样,具有处理HTML页面的功能,另外它还是一个Servlet和jSP容器,独立的Servlet容器是Tomcat的默认模式。

JSP(Java Server Pages)是由Sun Microsystems公司倡导、许多公司参与一起建立的一种动态网页技 术标准。JSP技术有点类似ASP技术,它是在传统的网页HTML文件(*.htm,*.html)中插入Java程序段(Scriptlet)和JSP 标记(tag),从而形成JSP文件(*.jsp)。 用JSP开发的Web应用是跨平台的,既能在Linux下运行,也能在其他操作系统上运行。

二、需求分析

2.1 可行性分析 实验室资产管理系统,基于b/s结构,运行在tomcat平台上使用MyEclipse开发的,主要使用本地计算机和网络计算机测试和使用,完全可以运行!

2.2基本功能

1、查看实验室总资产

2、查看实验室所有仪器和药品 3、搜索实验室药品和仪器

dstandardizationofsafetyproduction,andstrivetoachieve\nsicallysafe\safetysectionandisaunitofsecurityofficersresponsibleforminesafetydutiesandsupervisetheimplementationofthefollow-upto,andimplementationofthesystem,prosecution.PartImanagementsystems...Youcanusebrazierswhen,2--3metersfromthegroundandputthefireoutbeforethework,confirmthenofirebeforetheycanleave;Highway11non-staffinthemarginwithin50m,radiusoftheexcavationwork,andworkingwithin6metresoftheedgeandstayundertheumbrellaheading;12,blastingintothepitpersonnelmustfollowtheshootingguard'scommand,hidetosafety;13non-miningvehicles(includingbicycles,animal-drawnvehicle,motorvehicles,etc)willbebannedfromenteringthepitsandotherproductionareaonpainofheavyfines,resultinginaccidentstobeinvestigatedforresponsibility;14shootingthefollowingmechanicalsafetydistancesasfollows:categorynamemechanicalcannonsshallowholesandpopshootingexposedblastingunits:metersdiggingmachinerigcargunpowderotherequipment-pitequipment,especiallyanelectricalswitchandavarietyofsafetydevices,inadditiontospecifyingtheuseofresponsiblepersonnel,bananytouchingofotherpersonnel;16foundthatpowerlinesorcablesbreakinggroundbeforewithoutascertainingwhetherthecharged,prohibitsanyonefromtouching,andshouldleave5metersaway,andimmediatelynotifythepersonchecking;17withouttheleadership'sconsent,arenotallowedtotakethestrippedtrucks,watertankers,oiltankers,asaresultoftheca

2.3 数据库设计

1、仪器表

2、药品表

三、模块设计

3.1精确查询 精确查询可以输入要查询仪器或者药品的名称,也可以只输入一个字,在数据库里进行模糊查询,如果数据库中存在,则用户可以查看该仪器或者药品的信息,并且可以修改,若果没有,则显示不好意思,没有您搜索的结果!重新搜索(链接)。

代码:

package com.org.control;

import java.io.IOException; import java.io.PrintWriter; import java.sql.Connection; import java.sql.ResultSet;

dstandardizationofsafetyproduction,andstrivetoachieve\nsicallysafe\safetysectionandisaunitofsecurityofficersresponsibleforminesafetydutiesandsupervisetheimplementationofthefollow-upto,andimplementationofthesystem,prosecution.PartImanagementsystems...Youcanusebrazierswhen,2--3metersfromthegroundandputthefireoutbeforethework,confirmthenofirebeforetheycanleave;Highway11non-staffinthemarginwithin50m,radiusoftheexcavationwork,andworkingwithin6metresoftheedgeandstayundertheumbrellaheading;12,blastingintothepitpersonnelmustfollowtheshootingguard'scommand,hidetosafety;13non-miningvehicles(includingbicycles,animal-drawnvehicle,motorvehicles,etc)willbebannedfromenteringthepitsandotherproductionareaonpainofheavyfines,resultinginaccidentstobeinvestigatedforresponsibility;14shootingthefollowingmechanicalsafetydistancesasfollows:categorynamemechanicalcannonsshallowholesandpopshootingexposedblastingunits:metersdiggingmachinerigcargunpowderotherequipment-pitequipment,especiallyanelectricalswitchandavarietyofsafetydevices,inadditiontospecifyingtheuseofresponsiblepersonnel,bananytouchingofotherpersonnel;16foundthatpowerlinesorcablesbreakinggroundbeforewithoutascertainingwhetherthecharged,prohibitsanyonefromtouching,andshouldleave5metersaway,andimmediatelynotifythepersonchecking;17withouttheleadership'sconsent,arenotallowedtotakethestrippedtrucks,watertankers,oiltankers,asaresultofthecau import java.sql.SQLException; import java.sql.Statement;

import javax.servlet.ServletException; import javax.servlet.http.HttpServlet;

import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse;

import com.org.model.DateBaseUtil; import com.org.service.Filter; public class SelectSYServlet extends HttpServlet { public void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { Filter filter=new Filter(); if(filter.isValue(request, response)){ response.setContentType(\ PrintWriter out= response.getWriter(); request.setCharacterEncoding(\ String ykeywords = request.getParameter(\ if(null == rkeywords || rkeywords.equals(\ out.println(\请输入关键字!重新搜索\ return; }else{ String sql = \ System.out.println(sql); Connection conn = DateBaseUtil.getConn(); Statement stmt = null; ResultSet rs = null; try { stmt = conn.createStatement(); rs = stmt.executeQuery(sql); if(rs.next()){ printSheBei(out,rs); }else{ out.println(\不好意思,没有您搜索的结果!重新搜索\ } out.close(); DateBaseUtil.closeRs(rs);

联系客服:779662525#qq.com(#替换为@) 苏ICP备20003344号-4