J2EE is the most used language for web-programming. In this post we will discuss about concepts of J2EE and MySQL. In J2EE we will discuss about JDBC, Java Server Pages(JSP) and MySQL. JDBC stands for Java Database Connectivity which is widely use to connect the applications of Java with the database server. This helps to retrieve the data, modify and restore the data into the database server. It acts like a bridge between Java programming language and the database management system. Java Server Page is a technology to develop any web page. It supports the dynamic contents which help the developers to insert the java code into the HTML pages which starts with <% and end with %>. MySQL is the most important open source relational SQL database management system. It is one of the best RDBMS being used for developing web based software applications.
1. What is JDBC API?
Ans:- The JDBC API normally based on a set of interfaces, not classes. It is up to the manufactures of the driver to implement with their own set of classes. An example of a concrete class in JDBC API is DriverManager.
2. Define different types of clients in JDBC.
Ans:- Normally there are two types of clients available in JDBC. These are application and applet. Both run on Java virtual machine (JVM) but applet runs in a browser. Application has a main() method but applet has not. Because of these distinctions, it is useful to consider applications and applets as two different types of clients. On the other hands many types of clients are available as
3. Define JDBC driver.
Ans:- To connect a java application to a database using JDBC, JDBC drivers are normally used. This driver normally acts as an intermediary between the application and the database. There are normally four types of JDBC drivers which are used to connect the application with the database. These are as follows:
- Type 1: JDBC bridge drive
- Type 2: Native API part java driver
- Type 3: Network protocol Pure Java driver
- Type 4: Native protocol Pure java driver
4. Derive Oracle JDBC driver.
Ans:- Oracle provides types 2 and type 4 drivers for both client and server side use. Client side refers to the use of the driver in an application, applet or servlet. Server side refers to the use of driver inside the database. The type of oracle JDBC driver is as follows:
- JDBC OCI driver
- JDBC Thin driver
- JDBC internal driver
- JDBC server side thin server
5. Why JSP is used to develop a webpage?
Ans:- There are certain features of JSP for which it is used to develop a web page.
- JSP allows embedding dynamic elements in HTML pages.
- JSP always complied before it is processed by server side.
- JSP are built up on top of Java Servlet API.
- JSP pages can be used in combination with servlets that handle business logic.
6. What are the advantages of JSP?
Ans:- JSP has different advantages. These are listed below.
- The dynamic part is written in Java. It is more powerful and easy to use.
- It is portable.
- It is more convenient to write and modify.
- JSP are used to create the database connection between client and server.
7. What do you mean by JSP life cycle?
Ans:- JSP life cycle can be defined as the entire process from its creation till the destruction. The paths followed by JSP are as follows:
8. Why MySQL becomes the most popular RDBMS technology?
Ans:- MSQL becomes much popular because of the following reasons.
- MySQL is an open source license.
- It handles a large subset of functionality of the most powerful database package.
- It uses standard form of SQL language.
- It works on many operating systems and many languages.
- It works very quickly.
- It supports large database.
- It is customizable.
9. What are the RPMs available in Linux System for MySQL?
Ans:- For installation for MySQL on a Linux operating system, following RPMs are available for download.
10. Define the numeric data types used in MySQL.
Ans:- The following list shows the numeric data types used in MySQL.
- Decimal (m,d)
You may also like to visit: