retrieve Dept Name from table dept and retrieve list of employee from emp table for that dept in combobox

Ads

 
 
 

Share on Google+Share on Google+

Seshagiri
retrieve Dept Name from table dept and retrieve list of employee from emp table for that dept in combobox
0 Answer(s)      4 years and 2 months ago
Posted in : JSP-Servlet

I have an 2 textboxes and 1 combobox in my HTML page.

user will provide the input in one textbox then JSP code should retrieve data from database from table1 and display it in another textbox and from the same input paramter then its should retrieve the data from another table and display that list in combobox.

For example, In HTML page, we have Dept ID Textbox (Input Paramater), Dept Name Textbox, and Employee combobox.

If user enter 10 in Dept Number Textbox and onblur event,it should retrieve Dept Name from table dept(select deptno,deptname from dept where deptno=10) and retrieve list of employee from table emp for that dept in combobox using this query (select ename from emp e,dept d where e.deptno=d.deptno and d.deptno=10)

Out Put should be as below In Dept ID textbox it should be 10 In Dept Name textbox it should be Sales In employee Combobox,list of employee in dept 10

Can anybody help me in writing the JSP code for this.

Ads
View Answers
Ads









Related Tutorials/Questions & Answers:
retrieve Dept Name from table dept and retrieve list of employee from emp table for that dept in combobox
retrieve Dept Name from table dept and retrieve list of employee from emp table... table dept(select deptno,deptname from dept where deptno=10) and retrieve list of employee from table emp for that dept in combobox using this query (select ename
How to display all the rows in JSP ,MySQL select condition statement IN dept_table
is displayed.@select * from department where dept_no=10;My display code in JSP...;br><br> <form method="post" name="form"> <table border="1">...); String query = "select * from dept"; st = con.createStatement(); ResultSet rs
Advertisements
retrieve record from table
retrieve record from table  Hi. I have a field in database named stages. its datatype is varchar(60). It contains values chennai,trichy,kanchipuram for a single record. I have to retrieve these data from the field table. Actually
How to retrieve record from table
How to retrieve record from table  Hi. I have a field in database named stages. its datatype is varchar(60). It contains values chennai,trichy,kanchipuram for a single record. I have to retrieve these data from the field table
retrieve record from the field table
retrieve record from the field table  Hi. I have a field in database named stages. its datatype is varchar(60). It contains values chennai,trichy,kanchipuram for a single record. I have to retrieve these data from the field table
Retrieve Value from Table - Hibernate
Retrieve Value from Table   Hai friend, I need help, How can i retrieve values From database using hibernate in web Application. As I new to hibernate I couldn't find solution for this problem.. Can anyone help please.. 
Retrieve multiple data from database into Table.....
Retrieve multiple data from database into Table.....   hi........... I want to Retrieve multiple data from database into Table but i am not able to.... i am only able to retrieve one value not more than that. means in my
retrieve record from table and show it in HTML
retrieve record from table and show it in HTML  Hi. I have a field...,trichy,kanchipuram for a single record. I have to retrieve these data from the field table. Actually they are separated by comma. I want to take the values
HTML & MYSQL - retrieve record from table
HTML & MYSQL - retrieve record from table  Hi. I have a field...,trichy,kanchipuram for a single record. I have to retrieve these data from the field table. Actually they are separated by comma. I want to take the values as single
MYSQL retrieve record from Data table
MYSQL retrieve record from Data table  Hi. I have a field in database...,kanchipuram for a single record. I have to retrieve these data from the field table. Actually they are separated by comma. I want to take the values as single
I have to retrieve these data from the field table
I have to retrieve these data from the field table  Hi. I have... chennai,trichy,kanchipuram for a single record. I have to retrieve these data from the field table. Actually they are separated by comma. I want to take the values
retrieve the records from one table to another table by using cursors
retrieve the records from one table to another table by using cursors  ... int default 0; declare cur cursor for select name from emp; declare continue... from one table to another table by using cursors.The following is my procedure
Retrieve database from the table dynamically in jsp from oracle using servlet
Retrieve database from the table dynamically in jsp from oracle using servlet  Sir, I have created a table in oracle using eclipse, and added few columns dynamically. I want to retrieve the table with all columns dynamically
how to retrieve data from table with runtime values in sql?
how to retrieve data from table with runtime values in sql?  how to retrieve data from table with runtime values in sql? For example, I have table... to execute the command with the dates which I pass. I know how to retrieve a particular
Select data from Table in Database
the selected data from table in database. The select query in the database retrieve...; in simple select statement is given below select column name from table... table. select * from table; The select query retrieve all the column present
how to retrieve data from database using combobox value without using request.getParameter in jsp - JSP-Servlet
how to retrieve data from database using combobox value without using request.getParameter in jsp  Answer pl
Data retrieve from mysql database
Data retrieve from mysql database  Hi sir, please give some example... code retrieves the employee name in the dropdown. When the user selects any name...+"?name="+emp_value xmlHttp.onreadystatechange=stateChanged xmlHttp.open("GET",url
Retrieve The Data From MySql Datbase
Retrieve The Data From MySql Datbase   How to Retrieve The Data From MYSQL database TO Use Select the Emp_id Option.And Also Search Option
retrieve from database........
retrieve from database........  <p>hi i am not able to retrieve...,password); String query = "select * from employee"; st = con.createStatement...", "root", "root"); String query = "select * from employee where id
retrieve data from database with hyperlink
retrieve data from database with hyperlink  sir....i have one table called 'name' having two values i have to retrieve those data with a hyperlink... can i do it..help me sir its urgent.......????? for example-in table 'name' i
how to use StringTokenizer to retrieve the class name, attributes name and methods name from the Java Source Code
how to use StringTokenizer to retrieve the class name, attributes name and methods name from the Java Source Code  hi, I have done a program whereby... one problem which is retrieve the Class Name, Attributes Name and Methods Names
retrieve data from mysql database
retrieve data from mysql database  hi am not familiar in php.....even though i want to create combobox effectively.... my query is that when i have selected value on combobox which is to be retrieve the relevant data from mysql
how to retrieve data from database ?????/
how to retrieve data from database ?????/  how to retrieve data from database
how to retrieve data from database ?????/
how to retrieve data from database ?????/  how to retrieve data from database
how to retrieve data from database ?????/
how to retrieve data from database ?????/  how to retrieve data from database
how to retrieve data from database ?????/
how to retrieve data from database ?????/  how to retrieve data from database
Retrieving All Rows from a Database Table
All Rows from a table! Emp_code:   Emp_name: 10 ... string type parameter for executing the SQL statement. SELECT * FROM table_name... Retrieving All Rows from a Database Table   
how to retrieve data from database
how to retrieve data from database  unable to retrieve data from database using mySQL by using jsp sessions and beans for editing
data should not repeat in the drop down list when it is loading dynamically from database
, `DEPT_NAME` varchar(255) default NULL ); emp CREATE TABLE `emp... = con.createStatement(); ResultSet rs = stmt.executeQuery("Select * from emp where DEPT...;body> <select name='dept' onchange="showEmp(this.value)">
How to search the table name in MS SQL Database 2005 from application
How to search the table name in MS SQL Database 2005 from application  How to search the table name in MS SQL Database 2005 from application from our helpdesk application? application might be in html
retrieve data from database using jsf
retrieve data from database using jsf  Hello I want an example of source code to retrieve data from database i have a database (oracle) name as db1...),, name ,and city I want after enter value in textbox according idauthor i retrieve
Tutorials   
Java Spring Hibernate Struts Training fat image from db fat image from db fat image from db fat image from db unable to get value returned from javascript variable in page How to change image size before adding to mysql using jsp Design a registration.jsp page with input for user registration details Cart Quantity jsp servlet coding issue servlet,jsp login registration forms without database in ecalipse ide using hashmap to store the registraion details ? servlet,jsp login registration forms without database in ecalipse ide using hashmap to store the registraion details ? servlet,jsp login registration forms without database in ecalipse ide using hashmap to store the registraion details ? servlet,jsp login registration forms without database in ecalipse ide using hashmap to store the registraion details ? servlet,jsp login registration forms without database in ecalipse ide using hashmap to store the registraion details ? servlet,jsp login registration forms without database in ecalipse ide using hashmap to store the registraion details ? servlet,jsp login registration forms without database in ecalipse ide using hashmap to store the registraion details ? image pdf marking pdf marking Multiple image upload using JSP Read code from excel sheet and upload into database using JSP Student java about search engine Convert BLOB to PDF and save it to a location how to copy files from remote to local machine using SFTP SSL in java? Like Team viewer Socket and Servert -Jsp how to copy files from remote location to local using java? How To Store Multilple Images In MySQL database dynamically with image uploader and then retrieve them in image gallery using java how to create SOAP based web service in java? how to fetch data from mysql database table and draw a bar chart on that data using in jsp how to create users in LDAP using java? how to authenticate user using TIVOLI api in java? how to create users using IBM Tivoi API in jsp/servelet? Java/J2ee Please explain this code as many packages and classes are unknown to me .! how to download the uploaded folder files using jsp Login Query image is display from path of mysql database please reply the code to store dynamic fields in database? Reloading issue in jsp How to get Button Id ? calling one jap page from another jsp page login login Problem to get connection from DAO class to JDBC Page Loading Time Fix table's column's name row(1st row of the table) so that it does not move up when the table is scrolled up to view more rows below Sending hidden values

Ads

 
Advertisement null

Ads