Username is not defined. Query seems confusing too. THE ERROR that U receive is a
JSP based error where it clearly shows U that Username is not defined or declared.
Query is not even executed.
ASALAM wrote:
> Pls make your intention clear.
> The problem seems to be "Username" is not declared.
> Also I doubt whether the query is well formed.
>
> Pls post the entire source code.
>
> ASalam.
> ----- Original Message -----
> From: "Graeme McLaren" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Thursday, April 18, 2002 11:44 PM
> Subject: SQL SELECT Problem
>
> > Hi all, thank you for all the replies to my earlier SQL question, I've now
> > managed to INSERT data to my database. Now I have a problem selecting the
> > data which I have inserted.
> >
> > I have a form which is to be filled out to retrieve a username when a user
> > fills in their personal details. I'm getting the following error:
> >
> > 97. out.println(""+Username+"");
> > <------>
> > *** Error: No entity named "Username" was found in this environment.
> >
> > In my JSP I have:
> >
> > String EappName=request.getParameter("EappName");
> > String EappSurname=request.getParameter("EappSurname");
> > String address=request.getParameter("address");
> > String TownCity=request.getParameter("TownCity");
> > String Postcode=request.getParameter("Postcode");
> > String Phone=request.getParameter("Phone");
> > String email=request.getParameter("email");
> >
> > sql="SELECT Username FROM join11 WHERE('" +EappName+ "', '" +EappSurname+
> > "', '" +address+ "', '" +TownCity+ "', '" +Postcode+ "', '" +Phone+ "', '"
> > +email+ "' )";
> >
> > out.println("<p>"+EappName+"</p>");
> > out.println("<p>"+EappSurname+"</p>");
> > out.println("<p>"+address+"</p>");
> > out.println("<p>"+TownCity+"</p>");
> > out.println("<p>"+Postcode+"</p>");
> > out.println("<p>"+Phone+"</p>");
> > out.println("<p>"+Username+"</p>");
> > out.println("<p>"+email+"</p>");
> >
> > What has gone wrong here? Any advice is greatly appreciated.
> >
> > Thank you in advance,
> >
> > Graeme :)
> >
> > _________________________________________________________________
> > Join the world's largest e-mail service with MSN Hotmail.
> > http://www.hotmail.com
> >
> >
> ===========================================================================
> > To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
> JSP-INTEREST".
> > For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST
> DIGEST".
> > Some relevant FAQs on JSP/Servlets can be found at:
> >
> > http://archives.java.sun.com/jsp-interest.html
> > http://java.sun.com/products/jsp/faq.html
> > http://www.esperanto.org.nz/jsp/jspfaq.jsp
> > http://www.jguru.com/faq/index.jsp
> > http://www.jspinsider.com
> >
>
> ===========================================================================
> To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
> For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST".
> Some relevant FAQs on JSP/Servlets can be found at:
>
> http://archives.java.sun.com/jsp-interest.html
> http://java.sun.com/products/jsp/faq.html
> http://www.esperanto.org.nz/jsp/jspfaq.jsp
> http://www.jguru.com/faq/index.jsp
> http://www.jspinsider.com
===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST".
Some relevant FAQs on JSP/Servlets can be found at:
http://archives.java.sun.com/jsp-interest.html
http://java.sun.com/products/jsp/faq.html
http://www.esperanto.org.nz/jsp/jspfaq.jsp
http://www.jguru.com/faq/index.jsp
http://www.jspinsider.com