Current File : //home/obabain/autoclutchess_obaba_in/PatternDA.jsp
<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
    pageEncoding="ISO-8859-1"%>
     <%@ include file="Connection.jsp" %>
            <%@page import="java.sql.ResultSet"%>
            <%@page import="java.sql.*,java.util.*"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Insert title here</title>
</head>
<body>

               <%
             String item_name=request.getParameter("item_name");
             String pattern_by=request.getParameter("pattern_by");
             String methoding=request.getParameter("methoding"); 
             String itempattern_type=request.getParameter("itempattern_type"); 
             String mnum=request.getParameter("mnum"); 
             %>

             <%
			  try
               {
    	        if(item_name!=null ||item_name.length()!=0)
    	         {
    	          Statement st=con.createStatement(); 
                  int i=st.executeUpdate("insert into pattern_details(item_name,pattern_by,methoding,itempattern_type,order_no)values('"+item_name+"','"+pattern_by+"','"+methoding+"','"+itempattern_type+"','"+mnum+"')");
                  response.sendRedirect("Melting_LogSheet.jsp");
  				
                  }
    	        else
    	        {
    	        	response.sendRedirect("pattern_details.jsp");
    	        }
               }
               catch(Exception e)
               {
                System.out.print(e);
                e.printStackTrace();
               }   
			%> 


</body>
</html>