sql seever2008 模糊查询的时候用这个 and DESCRIPTIONs like '%'+#{description}+'%'
2017-02-22
发现直接传String数组过来也是没问题的:
<delete id = "deleteBath" parameterType = "java.lang.String">
DELETE FROM message WHERE ID in (
<foreach collection="array" item="item" separator=",">
#{item}
</foreach>
)
</delete>
<delete id = "deleteBath" parameterType = "java.lang.String">
DELETE FROM message WHERE ID in (
<foreach collection="array" item="item" separator=",">
#{item}
</foreach>
)
</delete>
2017-02-22
Quickly add testing datas:
INSERT message (SELECT id+1,command,description,content FROM message WHERE id = (SELECT count(id) FROM message));
INSERT message (SELECT id+1,command,description,content FROM message WHERE id = (SELECT count(id) FROM message));
2017-02-22
看看用注解方式定义servlet多么简洁!xml里面完全不用写了
@WebServlet("/List.action")
public class ListServlet extends HttpServlet{
@WebServlet("/List.action")
public class ListServlet extends HttpServlet{
2017-02-21