I am very new to java, Here i want to know how to show login error if i type a wrong password that was not saved in my mysql database?
System.out.println("Select count from users where pword='"+spword+"' and uname='"+suname+"');
rsT = stmt.executeQuery("select count from users where pword='" + spword + "' and uname='"+suname+"'");
if(rsT.next())
{
integer result = rsT.getint(1>);
result= <jsp:forward page="Menu.jsp" />;
}
else
{
integer result = rsT.getint(0);
result ="<center><h2>Invalid password</h2></center>";
errFlag = true;
}
rsT.close();