Home / JDBC

JDBC

Concept of Databases

Concept of Databases An important part of every business is to keep records. We need to keep records of our customers, the employees of our company, the emails etc. To …

Read More »

Database

A database is an organized collection of information. A simple example of a database are like your telephone directory, recipe book etc. A Relational model is the basis for any relational database management system (RDBMS). A …

Read More »

ACID Properties and Normalization

ACID properties are one of the important concepts for databases. ACID stands for Atomicity, Consistency, Isolation, and Durability. These properties of a DBMS allow safe sharing of data. Without these properties, the inaccuracy …

Read More »

INTRODUCTION TO JAVA DATABASE CONNECTIVITY

INTRODUCTION TO JAVA DATABASE CONNECTIVITY JDBC is Java application programming interface that allows the Java programmers to access database management system from Java code. It is developed by JavaSoft, a subsidiary of Sun Microsystems. Java Database …

Read More »

JDBC Architecture

JDBC Architecture JDBC is Java application programming interface that allows the Java programmers to access database management system from Java code. It is developed by JavaSoft, a subsidiary of Sun Microsystems. Java Database Connectivity in short called …

Read More »

JDBC Driver

JDBC Driver JDBC Driver Manager The JDBC DriverManager class defines objects which can connect Java applications to a JDBC driver. DriverManager has traditionally been the backbone of the JDBC architecture. It is quite …

Read More »

Introduction JDBC API

Introduction JDBC API When we need to use database drivers and the JDBC API while developing a Java application to retrieve or store data in database. The JDBC API classes and interfaces are …

Read More »

Loading a Driver

Loading a Driver The first step to develop a JDBC application is to load and register the required driver using the driver manager. We can load and register a driver: 1. Using …

Read More »

Connecting to a Database

Connecting to a Database We create an object of the Connection interface to establish a connection of the Java application with a database. We can create multiple Connection objects in a Java …

Read More »

Creating and Executing JDBC Statements

Creating and Executing JDBC Statements We need to create a Statement object to send request and retrieve result from a database. The Connection object provide the createStatement ( ) method to create a Statement …

Read More »

Handling SQL Exceptions

Handling SQL Exceptions The java.sql package provide the SQLException class, which is derived from the java.lang.Exception class. The SQLException class provides the following error information: 1. Error Message: It is a string that describes the …

Read More »

Introduction to resultset

Introduction to resultset in JDBC When we execute a query to retrieve data from a table using java application, the output of the query is stored in ResultSet object in a tabular format. A …

Read More »

Types of Result Sets

We can create various type of ResultSet objects tostore the output returned by a database after executing SQL statements. Various types of ResultSet objects are: a. Read only: It allow us to …

Read More »

Methods of ResultSet Interface in JDBC

Methods of ResultSet Interface in JDBC The ResultSet interface provides access to a table of data. A ResultSet object is usually generated by executing a Statement. A ResultSet maintains a cursor pointing …

Read More »

INTRODUCTION OF QUERYING AND MODIFYING DATA

INTRODUCTION OF QUERYING AND MODIFYING DATA PreparedStatement: This is an interface of java.sql package which extends Statement interface. If you want to execute Statement object many times then we should use PreparedStatement …

Read More »