search_do.jsp

来自「电子书店管理系统」· JSP 代码 · 共 22 行

JSP
22
字号
<%@ page language="java" errorPage="../error.jsp" %>
<%@ include file="../jstl.inc"%>
<c:choose>
	<c:when test="${param.type eq '0'}">
	    <c:set var="sql" value="select  product.productId as productId,item.itemid as itemid,product.name as name,item.listPrice as listPrice,item.unitCost as unitPrice,item.supplier  as publisher from product as product,item as item where product.name like '%${param.key}%' and product.productId=item.productId and item.status='1'"/>	    
	</c:when>
	<c:when test="${param.type eq '1'}">
	    <c:set var="sql" value="select  product.productId as productId,product.name as name,item.itemid as itemid,item.listPrice as listPrice,item.unitCost as unitPrice,item.supplier  as publisher from product as product,item as item where item.supplier like '%${param.key}%' and product.productId=item.productId and item.status='1'"/>	    
	</c:when>
	<c:when test="${param.type eq '2'}">
	    <c:set var="sql" value="select  product.productId as productId,product.name as name,item.itemid as itemid,item.listPrice as listPrice,item.unitCost as unitPrice,item.supplier  as publisher from product as product,item as item where product.category in(select catid from category where name like '%${param.key}%') and product.productId=item.productId and item.status='1'"/>	    
	</c:when>
	
</c:choose>
<c:import url="Product.jsp">
<c:param name="sql" value="${sql}"/>
</c:import>
	



⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?