answersLogoWhite

0


Best Answer

We can do validation by using JavaScript. Here we are using function Validate().

Iam creating one JSP name index.jsp & give a link to another JSP name basic.jsp. In that Jsp iam using Type 1 Jdbc Driver & giving a database connection

User Avatar

Wiki User

11y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: How validate and retrieve data from database in jsp?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Continue Learning about Engineering

How can you take data from a Java page to a HTML page simultaneously to the database and print that HTML file?

Your order is incorrect. The database exists and is populated with the data wanted on the page, Java extracts the data needed from the database and renders the page in the necessary HTML for the browser to view. You could see a JSP reference in the address for Jave Server Page or not.


How do you convert HTML to JSP?

You cannot. A JSP Page contains a lot more contents than just HTML. It contains JavaScript, Java Scriptlets etc. So a HTML cannot be directly converted to a JSP unless someone sits and adds the other contents to the JSP that makes it a JSP


Can HTML link to access databases?

No, HTML is not a programming language. It doesn't have the tools necessary to link to the database. You'll need something a little bit heavier, like PHP, ASP, JSP, or Ruby. (Or any of a billion others.)


What is the language primarily used for Internet based applications?

with single programming language we cannot do anything on the internet. Actually every application in java is divided into three layers. Presentation layer, Application layer, Data layer. Every layer has its own specification. Presentation layer role is to interact with client means presentation layer takes input from the user and send it to Application layer. Application layer is a business logic layer. All the logic is done in this layer. Data layer contains the data. for example:- suppose user enters student no. and student name in presentation layer, from here the data is send to application layer. In application layer we can write the logic for inserting, deleting, retriving and modifying the user data in database. From here the controller goes to datalayer to fetch data from database and sends the data back to user then the user see the corresponding data in the presentation layer. For presentation layer: html, jsp, velocity etc are used. For application layer: ejb, hibernate....... for data layer: oracle.......


What are the methods is defined by the jsp engine?

jspInit()jspDestroy()jspService

Related questions

How to Update data from jsp into database?

can i get update coding in jsp??


How do you get the image file from the database with JSP?

You can retrieve an image file from a database in JSP by writing a servlet that fetches the image from the database and streams it to the JSP page. The servlet will set the content type to "image/jpeg" or the appropriate image format and write the image data to the response output stream. In the JSP page, you can then display the image by setting the source attribute of the img tag to the servlet URL.


Difference between JSP and JAVA Script?

Hi, 1. JSP is a server side scripting while Javascript is as client side scripting language. 2. JSP also connects with database to fetch up the records from the database while javascript can be used for validate the code on client side.


How do you retrieve data from an SQL database based on the values selected from combo box using jsp?

Try to repair sql database owing to utility below. Software is able to restore sql databases any version of MS SQL Server.


How do you store and retrieve images from ms access or MySQL database using JSP source code required?

Retrieve sql data you may with the help of programming way. You need to software working with sql databases of any version SQL Server. I would recommend you to try tool below.


How do you create an address book using jsp and store all the information?

To create an address book using JSP, you can create a form to input contact information like name, email, phone number, etc. When the form is submitted, you can handle the data in a servlet and store it in a database like MySQL using JDBC. Then, you can retrieve and display this information in the JSP using Java servlets.


How to upload excel sheet data into a MySQL database using JSP and Servlets?

It is very easy to upload excel spreadsheet data into a MySQL database using JSP and servlets. Within Java there is a tool where you can designate the name and location of the file you would like to import. Once you furnish the file name Java server pages will do the work for you.


How can you take data from a Java page to a HTML page simultaneously to the database and print that HTML file?

Your order is incorrect. The database exists and is populated with the data wanted on the page, Java extracts the data needed from the database and renders the page in the necessary HTML for the browser to view. You could see a JSP reference in the address for Jave Server Page or not.


Can you create a database with only a form?

Yes , you can create a database using a form . But you have to do two things First make a form in html or jsp whatever you like. Then Connect the form to database using java database connectivity.Yes, we can create database with a form. First create a form using html or jsp then we can connect it to database using JDBC.


How do you retrieve data from an SQL database so that it can be viewed on a web page using JSP?

To retrieve data from an SQL database in a JSP page, you can use Java Database Connectivity (JDBC) to establish a connection with the database, execute SQL queries to fetch the data, and then display that data on the web page by embedding Java code within JSP. Make sure to properly handle exceptions, close connections, and consider security measures to prevent SQL injection attacks.


How the data is viewed in a JSP in the form of table?

You can display data in Tabular format in a JSP page using the HTML <Table> Tag. You can even assign dynamic values to the table using JSP Scriptlets. <% %>


How do you retrieve data from database with struts 2 and hibernate without touching the source code?

One way to retrieve data from a database using Struts 2 and Hibernate without modifying the source code is by writing queries in the Hibernate Query Language (HQL) directly in your configuration files, such as the Hibernate configuration XML file. You can also use criteria queries or named queries defined in the Hibernate mapping files (hbm.xml). Additionally, you can utilize Struts 2 tags and OGNL expressions in your JSP pages to display the retrieved data without altering the Java source code.