helpp....correct d code

Reply

Join Date: Jun 2008
Posts: 6
Reputation: insauciant is an unknown quantity at this point 
Solved Threads: 0
insauciant insauciant is offline Offline
Newbie Poster

helpp....correct d code

 
0
  #1
Jul 3rd, 2008
<%
try
{

//Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
//String url="jdbc:odbc:ODVS";
Connection conn=null;//DriverManager.getConnection(url,"downtime","downtime");
Class.forName("oracle.jdbc.driver.OracleDriver");
conn=DriverManager.getConnection("jdbc:oracleID10.10.10.2:1521LMDM","abc","abc");
String uid=request.getParameter("Username");
String pwd=request.getParameter("Password");


String sqlQry=("select * from USR_PASS_TB where Username='"+uid+"' and Password='"+pwd+"'");
Statement stmt=conn.createStatement();
ResultSet rs=stmt.executeQuery(sqlQry);

if(rs.next()==true)
{
//response.sendRedirect("../HTML/index_group.htm");
%>
<jsp:forward page="../HTML/index_group.htm" />
<%
}
else
{
//response.sendRedirect("..HTML/invalid_login.htm");
%>
<jsp:forward page="../HTML/invalid_login.htm" />
<%
}
rs.close();
conn.close();

}
catch(Exception e1)
{
System.out.println(e1);
}
%>



this code is not forwarding to index_group page..plzz help me out...plzzz
Reply With Quote Quick reply to this message  
Join Date: Mar 2008
Posts: 318
Reputation: Thirusha is an unknown quantity at this point 
Solved Threads: 51
Thirusha's Avatar
Thirusha Thirusha is offline Offline
Posting Whiz

Re: helpp....correct d code

 
0
  #2
Jul 3rd, 2008
I think this is in the incorrect forum.
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:



Other Threads in the Oracle Forum


Views: 1123 | Replies: 1
Thread Tools Search this Thread



Tag cloud for Oracle
About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC