Papitha Murugan 0 Newbie Poster
<%@ page  language="java" import="java.sql.*" errorPage="" %>

<%
Connection con = null;
Class.forName("sun.jdbc.odbc.JdbcOdbcDriver").newInstance();



Connection conn = DriverManager.getConnection("jdbc:odbc:mydsn","a", "a");
PreparedStatement psSelectRecord=null;
ResultSet rsSelectRecord=null;
Statement st=null;
String sqlSelectRecord=null;

String Name=null;
String id=null;
String doj=null;
String address=null;
String contact=null;
String dob=null;
String blood=null;
String gender=null;
String pan=null;
String martial=null;
String email=null;

String f1=null;
String f2=null;
String f3=null;
String f4=null;
String f5=null;

String r1=null;
String r2=null;
String r3=null;
String r4=null;
String r5=null;

String o1=null;
String o2=null;
String o3=null;
String o4=null;
String o5=null;


String q1=null;
String q2=null;
String q3=null;

String y1=null;
String y2=null;
String y3=null;

String c1=null;
String c2=null;
String c3=null;

String oq1=null;
String oq2=null;
String oq3=null;
String oq4=null;
String oq5=null;
String oq6=null;
String oq7=null;
String oq8=null;
String oq9=null;
String oq10=null;
String oq11=null;
String oq12=null;
String oq13=null;
String oq14=null;
String oq15=null;
String oq16=null;
String oq17=null;
String oq18=null;
String oq19=null;
String oq20=null;
String oq21=null;
String oq22=null;
String oq23=null;
String oq24=null;
String oq25=null;

String p1=null;
String p2=null;
String p3=null;
String p4=null;
String p5=null;
String p6=null;
String p7=null;
String p8=null;
String p9=null;
String p10=null;
String p11=null;
String p12=null;
String p13=null;
String p14=null;
String p15=null;
String p16=null;
String p17=null;
String p18=null;
String p19=null;
String p20=null;
String p21=null;
String p22=null;
String p23=null;
String p24=null;
String p25=null;

String e1=null;
String e2=null;
String e3=null;
String e4=null;
String e5=null;
String e6=null;
String e7=null;
String e8=null;
String e9=null;
String e10=null;
String e11=null;
String e12=null;
String e13=null;
String e14=null;
String e15=null;
String e16=null;
String e17=null;
String e18=null;
String e19=null;
String e20=null;
String e21=null;
String e22=null;
String e23=null;
String e24=null;
String e25=null;




sqlSelectRecord = "select * from EMP";

psSelectRecord=conn.prepareStatement(sqlSelectRecord);
        rsSelectRecord=psSelectRecord.executeQuery();
        if(rsSelectRecord.next())
		{

Name=rsSelectRecord.getString("Name");
id=rsSelectRecord.getString("Id");
doj=rsSelectRecord.getString("Doj");
address=rsSelectRecord.getString("Add");
contact=rsSelectRecord.getString("Contact");
dob=rsSelectRecord.getString("Dob");
blood=rsSelectRecord.getString("Blood");
gender=rsSelectRecord.getString("Gender");
pan=rsSelectRecord.getString("Pan");
martial=rsSelectRecord.getString("Martial");
email=rsSelectRecord.getString("Email");

f1=rsSelectRecord.getString("Family_Member_1");
f2=rsSelectRecord.getString("Family_Member_2");
f3=rsSelectRecord.getString("Family_Member_3");
f4=rsSelectRecord.getString("Family_Member_4");
f5=rsSelectRecord.getString("Family_Member_5");


r1=rsSelectRecord.getString("Relation_1");
r2=rsSelectRecord.getString("Relation_2");
r3=rsSelectRecord.getString("Relation_3");
r4=rsSelectRecord.getString("Relation_4");
r5=rsSelectRecord.getString("Relation_5");

o1=rsSelectRecord.getString("Occupation_1");
o2=rsSelectRecord.getString("Occupation_2");
o3=rsSelectRecord.getString("Occupation_3");
o4=rsSelectRecord.getString("Occupation_4");
o5=rsSelectRecord.getString("Occupation_5");


q1=rsSelectRecord.getString("Qualification_1");
q2=rsSelectRecord.getString("Qualification_2");
q3=rsSelectRecord.getString("Qualification_3");

y1=rsSelectRecord.getString("Year_1");
y2=rsSelectRecord.getString("Year_2");
y3=rsSelectRecord.getString("Year_3");

c1=rsSelectRecord.getString("Class_Obtained_1");
c2=rsSelectRecord.getString("Class_Obtained_2");
c3=rsSelectRecord.getString("Class_Obtained_3");

oq1=rsSelectRecord.getString("OtherQualification_1");
oq2=rsSelectRecord.getString("OtherQualification_2");
oq3=rsSelectRecord.getString("OtherQualification_3");
oq4=rsSelectRecord.getString("OtherQualification_4");
oq5=rsSelectRecord.getString("OtherQualification_5");
oq6=rsSelectRecord.getString("OtherQualification_6");
oq7=rsSelectRecord.getString("OtherQualification_7");
oq8=rsSelectRecord.getString("OtherQualification_8");
oq9=rsSelectRecord.getString("OtherQualification_9");
oq10=rsSelectRecord.getString("OtherQualification_10");
oq11=rsSelectRecord.getString("OtherQualification_11");
oq12=rsSelectRecord.getString("OtherQualification_12");
oq13=rsSelectRecord.getString("OtherQualification_13");
oq14=rsSelectRecord.getString("OtherQualification_14");
oq15=rsSelectRecord.getString("OtherQualification_15");
oq16=rsSelectRecord.getString("OtherQualification_16");
oq17=rsSelectRecord.getString("OtherQualification_17");
oq18=rsSelectRecord.getString("OtherQualification_18");
oq19=rsSelectRecord.getString("OtherQualification_19");
oq20=rsSelectRecord.getString("OtherQualification_20");
oq21=rsSelectRecord.getString("OtherQualification_21");
oq22=rsSelectRecord.getString("OtherQualification_22");
oq23=rsSelectRecord.getString("OtherQualification_23");
oq24=rsSelectRecord.getString("OtherQualification_24");
oq25=rsSelectRecord.getString("OtherQualification_25");

p1=rsSelectRecord.getString("ProjectKnowledge_1");
p2=rsSelectRecord.getString("ProjectKnowledge_2");
p3=rsSelectRecord.getString("ProjectKnowledge_3");
p4=rsSelectRecord.getString("ProjectKnowledge_4");
p5=rsSelectRecord.getString("ProjectKnowledge_5");
p6=rsSelectRecord.getString("ProjectKnowledge_6");
p7=rsSelectRecord.getString("ProjectKnowledge_7");
p8=rsSelectRecord.getString("ProjectKnowledge_8");
p9=rsSelectRecord.getString("ProjectKnowledge_9");
p10=rsSelectRecord.getString("ProjectKnowledge_10");
p11=rsSelectRecord.getString("ProjectKnowledge_11");
p12=rsSelectRecord.getString("ProjectKnowledge_12");
p13=rsSelectRecord.getString("ProjectKnowledge_13");
p14=rsSelectRecord.getString("ProjectKnowledge_14");
p15=rsSelectRecord.getString("ProjectKnowledge_15");
p16=rsSelectRecord.getString("ProjectKnowledge_16");
p17=rsSelectRecord.getString("ProjectKnowledge_17");
p18=rsSelectRecord.getString("ProjectKnowledge_18");
p19=rsSelectRecord.getString("ProjectKnowledge_19");
p20=rsSelectRecord.getString("ProjectKnowledge_20");
p21=rsSelectRecord.getString("ProjectKnowledge_21");
p22=rsSelectRecord.getString("ProjectKnowledge_22");
p23=rsSelectRecord.getString("ProjectKnowledge_23");
p24=rsSelectRecord.getString("ProjectKnowledge_24");
p25=rsSelectRecord.getString("ProjectKnowledge_25");


e1=rsSelectRecord.getString("E_LMS_1");
e2=rsSelectRecord.getString("E_LMS_2");
e3=rsSelectRecord.getString("E_LMS_3");
e4=rsSelectRecord.getString("E_LMS_4");
e5=rsSelectRecord.getString("E_LMS_5");
e6=rsSelectRecord.getString("E_LMS_6");
e7=rsSelectRecord.getString("E_LMS_7");
e8=rsSelectRecord.getString("E_LMS_8");
e9=rsSelectRecord.getString("E_LMS_9");
e10=rsSelectRecord.getString("E_LMS_10");
e11=rsSelectRecord.getString("E_LMS_11");
e12=rsSelectRecord.getString("E_LMS_12");
e13=rsSelectRecord.getString("E_LMS_13");
e14=rsSelectRecord.getString("E_LMS_14");
e15=rsSelectRecord.getString("E_LMS_15");
e16=rsSelectRecord.getString("E_LMS_16");
e17=rsSelectRecord.getString("E_LMS_17");
e18=rsSelectRecord.getString("E_LMS_18");
e19=rsSelectRecord.getString("E_LMS_19");
e20=rsSelectRecord.getString("E_LMS_20");

e21=rsSelectRecord.getString("E_LMS_21");
e22=rsSelectRecord.getString("E_LMS_22");
e23=rsSelectRecord.getString("E_LMS_23");
e24=rsSelectRecord.getString("E_LMS_24");
e25=rsSelectRecord.getString("E_LMS_25");

}
%>

<html>
<head>
<TITLE>MASTERS SOFTWARE</TITLE>
</head>

<body>
<form name="frm" action="saveUpdateRecord.jsp">
<td>Name</td>
<td><input type="text" name="name" value="<%=Name%>"></td>
<td>&nbsp;</td>

<td>Employee Id</td>
<td><input type="text" name="name" value="<%=id%>"></td>
<td>&nbsp;</td>


</form>
</body>
</html>


<%
      try{
          if(psSelectRecord!=null)
          {
           psSelectRecord.close();
          }
          
          if(rsSelectRecord!=null)
          {
           rsSelectRecord.close();
          }
          
          if(conn!=null)
          {
           conn.close();
          }
        }
        catch(Exception e)
        {
          e.printStackTrace(); 
        }
%>