servlet 中的查询数据库语句去到的值怎样传到jsp
publicvoiddoGet(HttpServletRequestrequest,HttpServletResponseresponse)throwsServletEx...
public void doGet(HttpServletRequest request, HttpServletResponse response)
throws ServletException, IOException {
}
public void doPost(HttpServletRequest request, HttpServletResponse response)
throws ServletException, IOException{
String s1 = request.getParameter("write");
String s2 = request.getParameter("ui");
if(s2.equals("id")){
String s3 = "ID";
System.out.println(JDBCConnect.searchData(s1,s3));
return;
}
else if(s2.equals("serivceid")){
String s3 = "SERIVCEID";
System.out.println(JDBCConnect.searchData(s1, s3));
return;
}else if(s2.equals("syskey")){
String s3 = "SYSKEY";
System.out.println(JDBCConnect.searchData(s1, s3));
return;
}else if(s2.equals("sysname")){
String s3 = "SYSNAME";
System.out.println(JDBCConnect.searchData(s1, s3));
return;
}else if(s2.equals("operDate")){
String s3 = "OPERDATE";
System.out.println(JDBCConnect.searchData(s1, s3));
return;
}else if(s2.equals("fromtype")){
String s3 = "FROMTYPE";
System.out.println(JDBCConnect.searchData(s1, s3));
return;
}else if(s2.equals("totype")){
String s3 = "TOTYPE";
System.out.println(JDBCConnect.searchData(s1, s3));
return;
}else if(s2.equals("iserror")){
String s3 = "ISERROR";
System.out.println(JDBCConnect.searchData(s1, s3));
return;
} 展开
throws ServletException, IOException {
}
public void doPost(HttpServletRequest request, HttpServletResponse response)
throws ServletException, IOException{
String s1 = request.getParameter("write");
String s2 = request.getParameter("ui");
if(s2.equals("id")){
String s3 = "ID";
System.out.println(JDBCConnect.searchData(s1,s3));
return;
}
else if(s2.equals("serivceid")){
String s3 = "SERIVCEID";
System.out.println(JDBCConnect.searchData(s1, s3));
return;
}else if(s2.equals("syskey")){
String s3 = "SYSKEY";
System.out.println(JDBCConnect.searchData(s1, s3));
return;
}else if(s2.equals("sysname")){
String s3 = "SYSNAME";
System.out.println(JDBCConnect.searchData(s1, s3));
return;
}else if(s2.equals("operDate")){
String s3 = "OPERDATE";
System.out.println(JDBCConnect.searchData(s1, s3));
return;
}else if(s2.equals("fromtype")){
String s3 = "FROMTYPE";
System.out.println(JDBCConnect.searchData(s1, s3));
return;
}else if(s2.equals("totype")){
String s3 = "TOTYPE";
System.out.println(JDBCConnect.searchData(s1, s3));
return;
}else if(s2.equals("iserror")){
String s3 = "ISERROR";
System.out.println(JDBCConnect.searchData(s1, s3));
return;
} 展开
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询