A Project Report On: Food Ordering Management System
A Project Report On: Food Ordering Management System
on
For
AISSCE 2019-20 Examination
SUBMITTED BY
Abhigyan Kumar Pandey
Roll No. 03
1. Introduction ---------------------------------------------------------------- 5
8. Biblography -------------------------------------------------- 26
Introduction
This software project is developed to automate the functionalities of order
tied with the database for easy access and interface to the database. Using
This software, being simple in design and working, does not require much
During coding and design of the software Project, Java NetBeans IDE, a
powerful front-end tool is used for getting Graphical User Interface (GUI)
In its current scope, the software enables user to retrieve and update
the information from centralized database designed with MySQL .
This software does not require much training time of the users due to
limited functionality and simplicity.
Database:
To find and retrieve just the data that meets conditions you specify,
including data from multiple tables, create a query. A query can
also update or delete multiple records at the same time, and
perform built-in or custom calculations on your data.
Role of RDBMS Application Program:
A computer database works as a electronic filing system, which has
a large number of ways of cross-referencing, and this allows the user
many different ways in which to re-organize and retrieve data. A
database can handle business inventory, accounting and filing and
use the information in its files to prepare summaries, estimates and
other reports. The management of data in a database system is
done by means of a general-purpose software package called a
Database Management System (DBMS). Some commercially
available DBMS are MS SQL Server, MS ACCESS, INGRES, ORACLE,
and Sybase. A database management system, therefore, is a
combination of hardware and software that can be used to set up
and monitor a database, and can manage the updating and
retrieval of database that has been stored in it. Most of the
database management systems have the following capabilities:
Creating of a table, addition, deletion, modification of records.
Retrieving data collectively or selectively.
The data stored can be sorted or indexed at the user's
discretion and direction.
Various reports can be produced from the system. These may
be either standardized report or that may be specifically
generated according to specific user definition.
Mathematical functions can be performed and the data
stored in the database can be manipulated with these
functions to perform the desired calculations.
To maintain data integrity and database use.
My SQL :
The management of data in a database system is done by means of
a general-purpose software package called a Database
Management System (DBMS). Some commercially available RDBMS
are MS SQL Server, MS ACCESS, INGRES, ORACLE, and Sybase.
MySQL, the most popular Open Source SQL database management
system, is developed, distributed, and supported by Oracle
Corporation. MySQL is named after co-founder Monty Widenius's
daughter, My. The name of the MySQL Dolphin (our logo) is “Sakila,”.
MySQL is a database management system.
A database is a structured collection of data. It may be
anything from a simple shopping list to a picture gallery or the
vast amounts of information in a corporate network. To add,
access, and process data stored in a computer database, you
need a database management system such as MySQL Server.
Since computers are very good at handling large amounts of
data, database management systems play a central role in
computing, as standalone utilities, or as parts of other
applications.
MySQL is based on SQL.
A relational database stores data in separate tables rather
than putting all the data in one big storeroom. This adds speed
and flexibility. The SQL part of “MySQL” stands for “Structured
Query Language.” SQL is the most common standardized
language used to access databases and is defined by the
ANSI/ISO SQL Standard. The SQL standard has been evolving
since 1986 and several versions exist. In this manual, “SQL-92”
refers to the standard released in 1992, “SQL:1999” refers to the
standard released in 1999, and “SQL:2003” refers to the current
version of the standard.
MySQL software is Open Source.
Open Source means that it is possible for anyone to use and
modify the software. Anybody can download the MySQL
software from the Internet and use it without paying anything. If
you wish, you may study the source code and change it to suit
your needs. The MySQL software uses the GPL (GNU General
Public License),
The MySQL Database Server is very fast, reliable, and easy to
use.
If that is what you are looking for, you should give it a try.
MySQL Server also has a practical set of features developed in
close cooperation with our users. You can find a performance
comparison of MySQL Server with other database managers on
our benchmark page. MySQL Server was originally developed
to handle large databases much faster than existing solutions
and has been successfully used in highly demanding
production environments for several years. Although under
constant development, MySQL Server today offers a rich and
useful set of functions. Its connectivity, speed, and security
make MySQL Server highly suited for accessing databases on
the Internet.
MySQL Server works in client/server or embedded systems.
The MySQL Database Software is a client/server system that
consists of a multi-threaded SQL server that supports different
backends, several different client programs and libraries,
administrative tools, and a wide range of application
programming interfaces (APIs).
Features of NetBeans
Database Design:
An important aspect of system design is the design of data storage
structure. To begin with a logical model of data structure is
developed first. A database is a container object which contains
tables, queries, reports and data validation policies enforcement
rules or contraints etc. A logical data often represented as a records
are kept in different tables after reducing anomalies and
redundancies. The goodness of data base design lies in the table
structure and its relationship.
This software project maintains a database named Project which
contains the following tables.
Table Design:
The database of Food Ordering contains 2 tables. The tables are
normalized to minimize the redundancies of data and enforcing the
validation rules of the organization. Most of the tables are designed
to store master records. The tables and their structure are given
below.
Table: Users
Column Name Type Size
Username (Primary Key) Varchar 4
Password Varchar 20
Contact_no Varchar 10
Address Varchar 100
Table: Order_Details
Column Name Type Size
D-Id (Primary Key) Char 2
D_name Varchar 25
Price Decimal (5,2)
Quantity Integer
Table: Orders
Column Name Type Size
O-Id (Primary Key) Varchar 10
Username Varchar 40
Date Varchar 20
Event Coding:
The software project for Food Ordering contains various Jforms along with programming
codes.JForms and their event coding are given below:
Frame: FoodOrderingLogin
}
else{
JOptionPane.showMessageDialog(this, "SELECT A OPTION FIRST");
}
signup.main(null);
Frame: Signup
try{
}
PreparedStatement pst=c.prepareStatement(qwery);
pst.setString(1,t1.getText());
pst.setString(2,t2.getText());
pst.setString(4,t3.getText());
pst.setString(3,t4.getText());
pst.execute();
pst.close();
c.close();
JOptionPane.showMessageDialog(this,"GREAT!YOU'VE SIGNED UP
SUCCESSFULLY");
}
catch(Exception e){
JOptionPane.showMessageDialog(this,e);
}
Frame: Main Menu
Order_Window.main(null);
this.dispose();
changeAccountSettings.main(null);
this.dispose();
FoodOrdering.main(null);
this.dispose();
Frame: Change Accounts Settings window
String url="jdbc:mysql://localhost:3306/project";
String user ="root";
String pwd="2000";
try {
System.out.println(u);
Connection c = DriverManager.getConnection(url, user, pwd);
PreparedStatement st= c.prepareStatement(qwery);
st.setString (1,t1.getText() );
st.setString (2,ta1.getText() );
st.setString (3,t2.getText() );
st.execute();
JOptionPane.showMessageDialog(this,"Changes Applied Successfully");
}
catch(Exception e)
{
JOptionPane.showMessageDialog(this,e);
}
MainMenu.main(null);
this.dispose();
if(b1.isSelected()){
}
if(b2.isSelected()){
}
if(b3.isSelected()){
}
if(b4.isSelected()){
}
if(b5.isSelected()){
}
if(b6.isSelected()){
qwery = "update order_details set quantity = ? where D_id="+'"'+"D6"+'"';
PreparedStatement st= c.prepareStatement(qwery);
st.setInt(1,1 );
st.execute();
if(b7.isSelected()){
}
if(b8.isSelected()){
}
if(b9.isSelected()){
}
catch(Exception e){
JOptionPane.showMessageDialog(this,e);
this.dispose();
checkout_window.main(null);
Frame: Review window
try{
Connection c = DriverManager.getConnection(url, user, pwd);
Statement st= c.createStatement();
ResultSet rs=st.executeQuery(qwery);
while(rs.next())
{
model.addRow(new Object[]{rs.getString("D_name"),
rs.getString("price"),rs.getString("quantity")});
p=Double.parseDouble(rs.getString("price"));
q=Double.parseDouble(rs.getString("quantity"));
t=t+(p*q);
}
}
catch(Exception e){
JOptionPane.showMessageDialog(this,e);}
String url="jdbc:mysql://localhost:3306/project";
String user ="root";
String pwd="2000";
String qwery="Select Address, contact_no from users where Username
="+'"'+s+'"';
try{
Connection c = DriverManager.getConnection(url, user, pwd);
Statement st= c.createStatement();
ResultSet rs=st.executeQuery(qwery);
if(rs.next())
{
ta1.setText(rs.getString("Address"));
t1.setText(rs.getString("contact_no"));
}
st.close();
c.close();
}
catch(Exception e){
JOptionPane.showMessageDialog(this,e);
String url="jdbc:mysql://localhost:3306/project";
String user ="root";
String pwd="2000";
String qwery="Insert into Orders values(?,?,?)",qwery2="select count(O_id
),sysdate() from orders;",d="";int o=0;
try{
Connection c = DriverManager.getConnection(url, user, pwd);
Statement st1= c.createStatement();
ResultSet rs=st1.executeQuery(qwery2);
if(rs.next())
{ o=Integer.parseInt(rs.getString("count(O_id )"))+1;
d=rs.getString("sysdate()");
}
PreparedStatement st= c.prepareStatement(qwery);
st.setString(1,"O"+o);
st.setString(2,s);
st.setString(3,d);
st.close();st1.close();c.close();
JOptionPane.showMessageDialog(this,"Order Placed!");
}
catch(Exception e){
JOptionPane.showMessageDialog(this,e);}
User Manual
Process to install Software:
Hardware Requirement-
Intel Pentium or similar processor based PC at Client/Server
end.
128 MB RAM and 4GB HDD space (for Database) is desirable.
Standard I/O devices like Keyboard and Mouse etc.
Printer is needed for hard-copy reports.
Local Area Network(LAN) is required for Client-Server Installation
Software Requirement-
Windows 10 OS is desirable.
NetBeans Version 8.0.2 or higher should be installed with JDK
and JVM.
MySQL Ver 5.5.62 with Project Database must be present at
machine.
Database Installation
Note: The PC must have MySQL server with user (root) and password
(2000) . If root password is any other password, it can be changed by
running MySQL Server Instance Configure Wizard.
Start Program MySQL MySQL Server MySQL Server Instance
Config Wizard
(3) http://www.mysql.org/
(4) http://www.netbeans.org/