Annexure
Micro-Project Proposal
Database-querying Application
1.0. Aims/Benefits of the Micro-Project
The aim of a microproject for a database querying application is to provide participants with a
practical understanding of database concepts and SQL through hands-on experience. This project
focuses on developing a user-friendly application that enables users to perform essential database
operations, such as creating, reading, updating, and deleting data (CRUD). By building this
application, participants enhance their problem-solving skills, learn to optimize queries for better
performance, and gain insights into effective data management.
2.0. Course Outcomes Addressed
a) Develop programs using GUI framework (AWT and Swing). Addressed
b) Handle events of AWT and Swing components. Addressed
c) Develop programs to handle events in Java Programming. Addressed
d) Develop java programs using networking concepts. Addressed
e) Develop programs using database. Addressed
f) Develop programs using Servlets. Not Addressed
3.0. Project Methodology
1. Focused on the selection of an appropriate topic for the micro-project.
2. Select the Topic i.e Datatbase-quering Application
3. Detailed study on my topic.
4. Gather All Information based on the topic of the micro-project.
5. Analysis and study of topic in detail
6. Following all the above methodologies to successfully completed my micro-project.
4.0. Action Plan
Name of
Sr. Planned Planned
Details of activity Responsible Team
No. Start Date Finish Date
Member
Information Gathering and
1 22-07-2024 22-07-2024 Shrutika Ghadge
Topic Finalization
Preparing Project Proposal
2 29-07-2024 31-07-2024 Shrutika Ghadge
and Approval
3 Implementing Project 05-08-2024 23-08-2024 Shrutika Ghadge
4 Preparing Project Report 27-08-2024 30-08-2024 Shrutika Ghadge
5 Presenting Project 02-09-2024 30-09-2024 Shrutika Ghadge
6 Submission of Project and Report 01-10-2024 15-10-2024 Shrutika Ghadge
MET’s Institute of Technology, Polytechnic, 1
Nashik
5.0. Resource Required
Sr.
Name of Resource/Material Specifications Qty. Remarks
No.
Windows 11, Intel Core
1 Computer System i5 (1.19 01
GHz), 16GB RAM
2 Java Development Kit JDK 10.0.1 01
MySQL Server 8.0 or
3 Database Package 01
above
Eclipse IDE for Enterprise
4 Java Programming Editor Java and Web Developers 01
- 2023-12
Name of Member with Roll No and Enrollment No.
Roll No Enrollment No Name of Member
1 2207760170 Ghadge Shrutika Chandrakant
Approved by
(Prof. Amit P. Bhuse )
Name and Signature of Staff
MET’s Institute of Technology, Polytechnic, 2
Nashik
Annexure–II
Micro-Project Report
Database-querying Application
1.0. Rationale
A database querying application that works with a MySQL server operates by first establishing a
connection to the server using specified credentials. Once connected, the application allows users
to input their query parameters through an intuitive interface. It then dynamically constructs SQL
queries based on this input, such as SELECT statements for data retrieval. These queries are sent
to the MySQL server, which processes them and returns the results. The application then formats
and displays the retrieved data in a user-friendly manner, often using tables or visualizations.
Additionally, it includes error handling mechanisms to provide feedback in case of issues like
syntax errors or connection problems, ensuring a smooth user experience while efficiently
managing data interactions with the MySQL database.
The database querying application that operates on a MySQL server is crucial for
efficiently managing and retrieving data in various contexts. This application enables users, even
those with limited technical expertise, to easily perform complex queries and obtain relevant
information from large datasets. By providing an intuitive interface, it allows users to filter, search,
and manipulate data without needing to write SQL code directly. This enhances productivity and
facilitates data- driven decision-making across different sectors, such as business analytics,
academic research, and customer relationship management. Moreover, the application can
streamline workflows by integrating features like data visualization and reporting, making it a
valuable tool for organizations looking to harness the power of their data effectively.
2.0. Aims/Benefits of the Micro-Project
The aim of the SQL Query Executor program is to provide a user-friendly interface for executing
SQL queries dynamically, allowing users to interact directly with a database without needing to
use command-line tools. The program enables users to input various SQL queries such as SELECT,
INSERT, UPDATE, and DELETE, offering flexibility in database management and interaction. It
simplifies the process of querying databases by displaying results in a structured table (JTable),
making it easy to view and interpret data.
3.0. Course Outcomes Addressed
a) Develop programs using GUI framework (AWT and Swing). Addressed
b) Handle events of AWT and Swing components. Addressed
c) Develop programs to handle events in Java Programming. Addressed
d) Develop java programs using networking concepts. Addressed
e) Develop programs using database. Addressed
f) Develop programs using Servlets. Not Addressed
MET’s Institute of Technology, Polytechnic, 3
Nashik
4.0. Literature Review
Relational Database Concepts:
The foundational principles of relational databases, introduced by Edgar F. Codd, emphasize data
organization in tables and the use of Structured Query Language (SQL) for efficient data
manipulation. This model supports data integrity and allows for complex querying.
Challenges with SQL:
While SQL provides powerful querying capabilities, its complexity can hinder usability for non-
technical users. Studies highlight the need for tools that simplify query construction, enabling a
broader audience to leverage database functionality without extensive training.
Graphical User Interfaces (GUIs):
The development of GUIs has been pivotal in enhancing user interaction with databases. By
offering visual elements such as forms and filters, GUIs make it easier for users to formulate and
execute queries, thus improving overall accessibility and efficiency.
Data Visualization Integration:
Integrating data visualization tools into querying applications enhances users' ability to interpret
and analyze data. Visual representations transform complex datasets into understandable
formats, facilitating better insights and informed decision-making.
Natural Language Processing (NLP):
Advances in NLP for querying databases using everyday language.
Impact on accessibility for users without technical backgrounds.
Performance Optimization:
Techniques for efficient query execution and data retrieval.
Importance of handling large datasets effectively.
Security Considerations:
Essential security measures, including access control and authentication.
Ensuring data integrity and user privacy in querying applications.
Current Trends and Future Directions:
Emerging technologies and their potential impact on database querying.
The ongoing need for user-centric design in database applications.
5.0. Actual Methodology Followed
Name of
Sr. Planned Planned
Details of activity Responsible Team
No. Start Date Finish Date
Member
Information Gathering and
1 22-07-2024 22-07-2024 Shrutika Ghadge
Topic Finalization
Preparing Project Proposal
2 29-07-2024 31-07-2024 Shrutika Ghadge
and Approval
3 Implementing Project 05-08-2024 23-08-2024 Shrutika Ghadge
4 Preparing Project Report 27-08-2024 30-08-2024 Shrutika Ghadge
5 Presenting Project 02-09-2024 30-09-2024 Shrutika Ghadge
6 Submission of Project and Report 01-10-2024 15-10-2024 Shrutika Ghadge
MET’s Institute of Technology, Polytechnic, 4
Nashik
6.0. Actual Resources Used
Book References:
1. Herbert Schildt, Java: The Complete Reference, Eleventh Edition, McGraw Hill Education,
New Delhi 2018, ISBN: 978-1260440232.
2. Cay S. Horstmann, Core Java Volume I—Fundamentals, Tenth Edition, Prentice Hall, New
Delhi 2015, ISBN: 978-0134177304.
3. Joshua Bloch, Effective Java, Third Edition, Addison-Wesley Professional, New Delhi 2017,
ISBN: 978-0134685991.
Web References:
1 Geeks for Geeks - https://www.geeksforgeeks.org/introduction-to-java-programming/
2 Tutorials point Java JDBC Tutorial- https://www.tutorialspoint.com/jdbc/index.htm3
3 Java Basics – YouTube - https://www.youtube.com/watch?v=grEKMHGYyns
4 Database Connectivity YouTube- https://youtu.be/7v2OnUti2eM?si=quqT49IWvyV3FbOk
Sr.
Name of Resource/Material Specifications Qty. Remarks
No.
Windows 11, Intel Core
1 Computer System i5 (1.19 01
GHz), 16GB RAM
2 Java Development Kit JDK 10.0.1 01
MySQL Server 8.0 or
3 Database Package 01
above
Eclipse IDE for Enterprise
4 Java Programming Editor Java and Web Developers 01
- 2023-12
7.0. Output of the Micro-Project
We have successfully execute the SQL Query like INSERT,CREATE,UPDATE,DELITE,SELECT.
8.0. Skill Developed/Learning outcomes of this Micro-Project
1. Database Management Knowledge:
Gained a solid understanding of relational database concepts, including tables, relationships,
normalization, and indexing, which are essential for effective data organization and retrieval.
2. SQL Proficiency:
Developed the ability to write, execute, and optimize SQL queries, enhancing skills in data
manipulation and retrieval for various applications.
3. User Interface (UI) Design:
MET’s Institute of Technology, Polytechnic, 5
Nashik
Acquired skills in designing intuitive user interfaces that improve user experience, focusing on
usability, accessibility, and visual appeal.
4. Programming Skills:
Enhanced programming skills through the implementation of backend logic using languages such
as Python, Java, or JavaScript, reinforcing understanding of application development.
5. Problem-Solving and Critical Thinking:
Improved problem-solving abilities by troubleshooting issues related to data queries,
performance, and user interactions, fostering analytical thinking.
6. Data Visualization Techniques:
Learned to incorporate data visualization tools to effectively present data insights, making
complex information easier to understand and analyze.
9.0. Application of this Micro-Project
1. Educational Tools
2. Personal Projects
3. Learning Tool for Developers
4. Integration into Larger Systems
5. Small Business Management
6. Research Data Management
7. Event Management
8. Database Practice Tool
MET’s Institute of Technology, Polytechnic, 6
Nashik
Annexure - IV
Micro-Project Evaluation Sheet
Name of Student: Shrutika Chandarakant Ghadge Enrollment No:2207760170
Name of Programme: Computer Engineering Semester: Fifth
Course Title: Advanced Java Programming Code: 22517
Title of the Micro-Project: Database-querying Application
Course Outcomes Achieved:-
a) Develop programs using GUI framework (AWT and Swing). Addressed
b) Handle events of AWT and Swing components. Addressed
c) Develop programs to handle events in Java Programming. Addressed
d) Develop java programs using networking concepts. Addressed
e) Develop programs using database. Addressed
f) Develop programs using Servlets. Not Addressed
Sr. Characteristics to Poor (Marks Average Good Excellent Sub-
No. be assessed 1-3) (Marks 4-5) (Marks 6-8) (Marks 9-10) Total
(A) Process and Product Assessment (Convert above total marks out of 6 Marks)
1 Relevance to the course
Literature Review/
2
Information Collection
Completion of the Target
3 as per Project Proposal
Analysis of Data and
4
Representation
Quality of
5
Prototype/Model
6 Report Preparation
(B) Individual Presentation/Viva (Convert above total marks out of 4 Marks)
7 Presentation
8 Viva
(A) Process and Product Assessment (B) Individual Total Marks
(6 Marks) Presentation/Viva (4 (10 Marks)
Marks)
Comments/Suggestions about team work/leadership/inter-personal communication (if any)
Name and Designation of the Teacher: Prof. Amit P. Bhuse
Dated Signature:
MET’s Institute of Technology, Polytechnic, 7
Nashik
Program Code:
package com.database;
import javax.swing.*;
import java.awt.*;
import java.awt.event.*;
import java.sql.*;
import java.util.ArrayList;
public class SQLOperation5 extends JFrame implements ActionListener {
JLabel lbname;
JTextArea queryArea;
JButton executeButton, insertButton, updateButton, deleteButton;
JTable resultTable;
JScrollPane scrollPane;
Connection;
public SQLOperation5() {
this.setTitle("SQL Query Executor");
this.setSize(600, 400);
this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
this.setLayout(new BorderLayout());
this.setVisible(true);
lbname = new JLabel("Enter SQL Query:");
queryArea = new JTextArea(5, 40);
executeButton = new JButton("Execute
Query"); insertButton = new JButton("Insert");
updateButton = new
JButton("Update"); deleteButton = new
JButton("Delete"); resultTable = new
JTable();
scrollPane = new JScrollPane(resultTable);
JPanel topPanel = new JPanel();
topPanel.setLayout(new BorderLayout());
JPanel labelPanel = new JPanel(new FlowLayout(FlowLayout.LEFT));
labelPanel.add(lbname);
JPanel buttonPanel = new JPanel(new FlowLayout(FlowLayout.RIGHT));
buttonPanel.add(executeButton);
buttonPanel.add(insertButton);
buttonPanel.add(updateButton);
buttonPanel.add(deleteButton);
topPanel.add(labelPanel, BorderLayout.WEST);
topPanel.add(buttonPanel, BorderLayout.CENTER);
MET’s Institute of Technology, Polytechnic, 8
Nashik
int v = ScrollPaneConstants.VERTICAL_SCROLLBAR_ALWAYS;
int h = ScrollPaneConstants.HORIZONTAL_SCROLLBAR_ALWAYS;
JScrollPane scrollpanearea = new JScrollPane(queryArea, v, h);
topPanel.add(scrollpanearea, BorderLayout.SOUTH);
add(topPanel, BorderLayout.NORTH);
add(scrollPane, BorderLayout.CENTER);
executeButton.addActionListener(this);
insertButton.addActionListener(this);
updateButton.addActionListener(this);
deleteButton.addActionListener(this);
}
public void actionPerformed(ActionEvent e)
{ String query =
queryArea.getText().trim(); if (!
query.isEmpty()) {
if (e.getSource() == executeButton)
{ executeSQLQuery(query);
} else if (e.getSource() == insertButton) {
executeInsert(query);
} else if (e.getSource() == updateButton) {
executeUpdate(query);
} else if (e.getSource() == deleteButton) {
executeDelete(query);
}
} else {
JOptionPane.showMessageDialog(null, "Please enter a query.");
}
}
private void DBConnection() {
try {
Class.forName("com.mysql.cj.jdbc.Driver");
connection = DriverManager.getConnection("jdbc:mysql://localhost:3306/shrutika ", "root",
"pass@123");
} catch (Exception e) {
e.printStackTrace();
JOptionPane.showMessageDialog(null, "Database connection error: " + e.getMessage());
}
}
private void executeSQLQuery(String query) {
try {
Statement stmt = connection.createStatement();
ResultSet rs = stmt.executeQuery(query);
updateTableModel(rs);
} catch (SQLException e) {
MET’s Institute of Technology, Polytechnic, 9
Nashik
e.printStackTrace();
JOptionPane.showMessageDialog(null, "SQL error: " + e.getMessage());
}
}
private void updateTableModel(ResultSet rs) throws SQLException {
ResultSetMetaData metaData = rs.getMetaData();
int columnCount = metaData.getColumnCount();
ArrayList<String> columnNames = new ArrayList<>();
for (int i = 1; i <= columnCount; i++) {
columnNames.add(metaData.getColumnName(i));
}
ArrayList<ArrayList<Object>> data = new ArrayList<>();
while (rs.next()) {
ArrayList<Object> row = new ArrayList<>();
for (int i = 1; i <= columnCount; i++) {
row.add(rs.getObject(i));
}
data.add(row);
}
Object[][] dataArray = new Object[data.size()][columnCount];
for (int i = 0; i < data.size(); i++) {
dataArray[i] = data.get(i).toArray();
}
resultTable.setModel(new javax.swing.table.DefaultTableModel(dataArray, columnNames.toArray()));
}
private void executeInsert(String query) {
executeUpdate(query, "inserted");
}
private void executeUpdate(String query) {
executeUpdate(query, "updated");
}
private void executeDelete(String query) {
executeUpdate(query, "deleted");
}
private void executeUpdate(String query, String action) {
try {
Statement stmt = connection.createStatement();
int rowsAffected = stmt.executeUpdate(query);
JOptionPane.showMessageDialog(null, rowsAffected + " row(s) " + action + ".");
queryArea.setText("");
MET’s Institute of Technology, Polytechnic, 10
Nashik
} catch (SQLException e)
{ e.printStackTrace();
JOptionPane.showMessageDialog(null, "SQL error: " + e.getMessage());
}
}
public static void main(String[] args) {
SQLOperation5 app = new SQLOperation5();
app.DBConnection();
}
}
Output:-
MET’s Institute of Technology, Polytechnic, 11
Nashik
MET’s Institute of Technology, Polytechnic, 12
Nashik
MET’s Institute of Technology, Polytechnic, 13
Nashik