Monday, November 6, 2017

Spring JDBC - Program to connect Database using jdbcTemplate

Spring jdbc is very important as all the enterprise level application always use database and Spring JDBC comes in picture when we connect database with java application using spring framework.

Below  program we are using the spring jdbcTemplate along with Java.

The structure of the project would be like below

Database we are using is MYSQL.

Below is the Program

Above is the schema and the query of the schema is as below

CREATE TABLE `Organization` (
  `id` int(11) NOT NULL,
  `slogan` varchar(45) DEFAULT NULL,
  `totalEmployee` int(11) DEFAULT NULL,
  `yearOfIncorporation` int(11) DEFAULT NULL,
  `name` varchar(45) DEFAULT NULL,
  `address` varchar(45) DEFAULT NULL,
  PRIMARY KEY (`id`)

You can download the full program from my git hub CLICK HERE

Hope this will help you in understanding the Coding part . If you face any issue please leave us a comment , Happy to help you :)

Thanks for reading


Post a Comment