I tried to retrive the data from database its perfect but iam getting all the datas but my problem is i can't retrive a single data from database and i need to display that data in jsp page.
I tried but i am not getting any error, iam getting my jsp page but after iam giving a data and click the submit button its in blank only i can't retrive them please help me to solve my issue.
My database is MYSql. just two datas if i retrive from database and shown in jsp field mens then i will develop remaing information.
my database code is :
My jsp code is
I know that iam doing mistake but i can't find it in google also i tried iam getting fail only Please Guide me to solve my issue. no one is not there to guide me in my office iam developing alone so please solve my issue as soon as possible and give guide to me.Because by using this idea only iam going develop my project in frameworks is just foundation so please put my foundation strongly.
I have tried but still ame issue. now iam give my full sapmle code its for sample only later i will make it with servlet code, my code in jsp page in jsp page java code its not perfect i know but for time being iam using like this don't mistake me.
I can't understand your problem.What i understood is
You have User Name and Password in your database and have a jsp page that contains username and passwords input text fileds when you type user name and then click submit button you get the
password related to that username .
For this you have to use ajax.This is the better way . Leave ajax now do what i say
I am Placing System.out.println() and observer the outputs
Please execute query in sql browser.(I placed query string in System.out.println()) execute That .
Check Web.xml after close <web-app> tag again pasted some mapping there.
Joined: Jan 05, 2012
Thanks you for your reply.
From database it is taking username and password but that username and password is not showing in jsp input field.
Please understand my question, iam haveing one jsp page its having 2 fields one is username and password in database iam having some username and password. if i gave username and click ok means in username field it wants to show username and in password field it wants to take the password from database and that password wants to reflect in jsp page.
It is same as find option, data is taken from database but that data is not fetching in jsp page. iam running in eclipse in console tab it is showing the information but in jsp page in particular place it is not reflecting. i don't know that i want to keep one jsp page or 2jsp page.
Please guide me to solve my issue. please help me. to ask this doute also iam not having any member to help me in my office,iam developing alone please guide me.
Thanks in advance.
Joined: Jan 05, 2012
i have finished the task but now iam facing one more problem.
While iam running my jsp page its showing null in input field,i know why its showing but i don't know how to solve my issue please help me. Iam passing my values in the jsp page for that resone its showing null but if i pass the values only from database its showing values in input filed . please help me.
My find.jsp page is
If you note in my jsp page i have given value="<%=request.getAttribute("user") %>" for that resone only its showing null values, then by using this line code only iam getting values from database in input field. please help me to avoid my issue.
My servlet code is:
i wants to use same jsp page to find the values it will be possible or not because for everythig we keep 2pages means its not a right way to develop, so iwants to use same jsp page.