tollgate systemmobile showroom billing and inventory management is developed for established mobile...

99
1 CHAPTER-1 INTRODUCTION Automated toll collection (ATC) is a technology enabling the electronic collection of toll payments. It has been studied by researchers and applied in various highways, bridges, and tunnels requiring such a process. This system is capable of determining if the car is registered or not, and then informing the authorities of toll payment violations, debits, and participating accounts. The most obvious advantage of this technology is the opportunity to eliminate congestion in tollbooths, especially during festive seasons when traffic tends to be heavier than normal. It is also a method by which to curb complaints from motorists regarding the inconveniences involved in manually making payments at the tollbooths. Other than this obvious advantage, applying ATC could also benefit the toll operators. Thus, the ATC system is a win-win situation for both the motorists and toll operators, which is why it is now being extensively used throughout the world. An ATC system commonly utilizes radiofrequency identification (RFID) technology. RFID is a generic term used to identify technologies utilizing radio waves to automatically identify people or objects . RFID technology was first introduced in 1948 when Harry Stockman since then, and has been implemented in various applications, such as in warehouse management, library system, attendance system, theft prevention, and so on. In general, RFID is used for tracking, tracing, and identifying objects. A complete RFID system consists of a transponder (tag), reader/writer, antenna, and computer host. The transponder, better known as the tag, is a microchip combined with an antenna system in a compact package. The microchip contains memory and logic circuits to receive and send data back to the reader. These tags are classified as either active or passive tags. Active tags have internal batteries that allow a longer reading range, while passive tags are powered by the signal from its reader and thus have shorter reading range. A reader contains an antenna to transmit and receive data from the tag. The reader also contains a decoder and an RF module. It could be mounted or built as a portable handheld device.

Upload: reena0307

Post on 14-Jan-2016

7 views

Category:

Documents


0 download

DESCRIPTION

Mobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is developed. It will have all the basic module to manage the show room

TRANSCRIPT

Page 1: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

1

CHAPTER-1

INTRODUCTION

Automated toll collection (ATC) is a technology enabling the electronic collection of toll

payments. It has been studied by researchers and applied in various highways, bridges, and

tunnels requiring such a process. This system is capable of determining if the car is registered or

not, and then informing the authorities of toll payment violations, debits, and participating

accounts. The most obvious advantage of this technology is the opportunity to eliminate

congestion in tollbooths, especially during festive seasons when traffic tends to be heavier than

normal. It is also a method by which to curb complaints from motorists regarding the

inconveniences involved in manually making payments at the tollbooths. Other than this obvious

advantage, applying ATC could also benefit the toll operators.

Thus, the ATC system is a win-win situation for both the motorists and toll operators, which is

why it is now being extensively used throughout the world.

An ATC system commonly utilizes radiofrequency identification (RFID) technology. RFID is a

generic term used to identify technologies utilizing radio waves to automatically identify people

or objects . RFID technology was first introduced in 1948 when Harry Stockman since then, and

has been implemented in various applications, such as in warehouse management, library

system, attendance system, theft prevention, and so on. In general, RFID is used for tracking,

tracing, and identifying objects.

A complete RFID system consists of a transponder (tag), reader/writer, antenna, and computer

host. The transponder, better known as the tag, is a microchip combined with an antenna system

in a compact package. The microchip contains memory and logic circuits to receive and send

data back to the reader. These tags are classified as either active or passive tags. Active tags have

internal batteries that allow a longer reading range, while passive tags are powered by the signal

from its reader and thus have shorter reading range.

A reader contains an antenna to transmit and receive data from the tag. The reader also contains a

decoder and an RF module. It could be mounted or built as a portable handheld device.

Page 2: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

2

CHAPTER-2

SYSTEM ANALYSIS

System analysis is a detailed study of various operations performed by a system and with their

relationships within and outside the system. It deals with defining all the boundaries of system

and determining whether or not candidate systems should consider other related systems.

2.1 EXISTING SYSTEM

Road tolls were levied traditionally for a specific access (e.g. city) or for a specific infrastructure

(e.g. roads, bridges). Tolls are a form of user tax that pays for the cost of road construction and

maintenance without raising taxes on non-users. tolls are paid by hand at a toll gate, payments

are generally made in cash. user deposits a certain amount at a tollgate depending on his vehicle

type and the authorities allow passage or entry.

In the current times of increasing traffic on the road, it is important to collect the toll tax in a

managed and controlled process so that it doesn't result in a total unorganized jungle of traffic.

It is very challenging to handle a vehicular flow by a manual system of revenue collection. Poor

management at toll plaza may result into great chaos and revenue loss, which is not desired.

2.2 PROPOSED SYSTEM

In this application “Automated Toll Collection System” toll collection is carried out using RFID

technology the reader reads the information in the tag and the transaction takes place through a

centralized database. If the balance on the prepaid card is low a text message is forwarded to the

tag owners phone prompting for a recharge. The RFID tag on the vehicle also helps in the

recovery of a lost vehicle when a police case is lodged by its owner.

Road users also have the chance to choose either a prepaid or a postpaid tag. At the entrance

point, the system will record the users’ information with their preferred method (i.e., prepaid or

postpaid).Then, at the end of the entrance point, the system will calculate the kilometers driven

and then deduct payment straight from the tag (for prepaid users); if the balance is not enough,

the barrier will still be lifted, but a warning email or an SMS will be sent to the owner. If the

owner fails to pay the excessive amount, the tag will be barred. For the postpaid system, a bill

Page 3: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

3

will be sent to their respective homes at the end of every month. If the users fail to pay the

amount, their tags will also be barred. Using this system, all problems related to manual toll fee

collection will be eliminated, there by achieving a higher efficiency rate per transaction. This is

because this system requires no human interactions that could lead to cheating and human errors.

2.3 FUNCTIONALITY

2.3.1 Functional Requirements:

Registration: First vehicle owner needs to register by giving basic details, then comes the

registration of an account pertaining to the owner -either prepaid or postpaid, during registration

the owner needs to deposit certain amount in his account. Then vehicle information needs to be

entered. This registration issues an RFID tag id to vehicle. Registration is successful.

The second part of this module is for the tollgate management, tollgates need to register or the

various toll amounts levied on different vehicle types that approach a tollgate

Tracking: As the vehicle approaches the toll gate the RFID readers placed beneath the toll area

identifies the RFID tag and amount is deducted from its prepaid account. A text message is send

to the owner’s phone as soon as the tag is detected at the tollgate, assuring the owner of the

transaction.

Recharge: The owners account can be managed such that the account balance can be recharged

when the balance is low, the owners account id should be entered for using this functionality.

The account balance before the recharge is done can be viewed on this page.

Complaint: A complaint should be lodged on the theft on the complaint page. The vehicles

details along with the 12 digit RFID tag ID should be entered. This helps in identifying stolen

vehicles at the tollgate.

No Parking: A reader is placed at the No Parking zones and if the vehicles are parked in that

location the RFID tag is identified and a specified fine amount will be deducted from its account.

2.3.2 Non-Functional Requirements:

Performance Requirements

Maintainability: The software can be restored to a specified condition within a specified

Page 4: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

4

period of time.

Extensibility: New capabilities can be added to the software without major changes to

the underlying architecture.

Safety Requirements

Usability: The software user interface must be intuitive (and often aesthetically pleasing)

to its target user/audience

Security: The software is able to withstand hostile acts and influences.

2.4 REQUIREMENTS

2.4.1 Hardware Specifications

RFID tag/transponder

RFID reader

Host computer

2.4.2 Software Specifications

• OS: windows XP or windows 7

• LANGUAGE: JDK 1.6 or above

• IDE: Eclipse Galileo

• DATABASE: Oracle 10g

• PLUGINS: Jigloo

Page 5: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

5

CHAPTER-3

SYSTEM DESIGN

3.1 INTODUCTION

Systems design is the process or art of defining the architecture, components, modules,

interfaces, and data for a system to satisfy specified requirements. Once the software

requirements are analyzed and specified, the software design involves three technical activities.

design, code generation and testing that are required to build and verify the software. The design

activities are of main importance in this phase because in this activity decisions ultimately

affecting the success of the software implementation and its ease of maintenance are made.

These decisions have the final bearing upon the reliability and maintainability of the system

.Design is the only way to accurately transfer the customer requirements into finished software

or system.

3.1.1 Admin Login

Fig 3.1 Flow of Admin Login

Page 6: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

6

3.1.2 Owner Registration

Fig 3.1.2 Flow of Owner Registration

3.1.3 Registered User

Fig 3.1.3 Flowchart for Registered User

Page 7: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

7

3.2 UML DIAGRAMS

UML, the unified Modeling Language, is a visual language for specifying, constructing, and

Documenting all the artifacts of systems.UML can be used with all processes, throughout the

development life cycle, and across different implementation technologies. The UML diagrams

represent three different views of a system model.

3.2.1 Functional Requirement View

It emphasizes on the functional requirements of the system from the user’s point of view.

This includes use case diagrams.

3.2.2 Static Structural View

It emphasizes the static structure of the system using objects, attributes, operations and all

relationships. This includes class diagrams.

3.2.3 Dynamic Behavior View

It emphasizes the dynamic behavior of the system by showing collaborations among

objects and changes to the internal states of objects. This includes sequence diagrams, activity

diagrams

3.2.4 Use Case Diagrams

Use case diagrams overview the usage requirements for a system. They describe “the

meat” of the actual requirements.

.

Page 8: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

8

Use case diagram for Automated Tollgate System

Fig 3.2.4 Use case diagram for Automated Toll System

User Registration

Vehicle Registration

Tollgate Registration

Login

Registration

Traking Vehicle

Theft Vehicle Complaint

Admin

No Parking Zone

Page 9: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

9

3.3 Sequence Diagrams

A sequence diagram depicts the sequence of actions that occur in a system.The

invocation of methods in each object, and the order in which the invocation occurs is captured in

a sequence diagram.This makes the sequence diagram a very useful tool to easily represent the

dynamic behaviour of a system

Fig 3.3.1: Sequence diagram

Admin

Login

Enter Admin Credentials

Validates Admin Credentials

Send Success / Failure Message

Sequence Diagram for Admin Login

Page 10: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

10

Fig 3.3.1: Sequence diagram for User Registration

Admin

Login User

Registration

Sequence Diagram for User Registration

Enter Admin Credentials

Validates the Credentials

Send success Message

Admin enter Registration page and fill the details

Validates the details

Success Message

Page 11: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

11

Fig 3.3.3: Sequence diagram for Toll Registration

AdminLogin Tollgate

Registration

Sequence Diagram for Tollgate Registration

Enter Admin

Validates

Send Success Message

Admin Selects Tollgate Registration Page and Fil the Details

Validates the Details

Success Message

Page 12: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

12

Fig 3.3.4: Sequence diagram for Vehicle Registration

AdminLogin Vehicle

Registration

Enter Admin Credentials

Validates Credentials

Send Success Message

Admin Selects Vehicle Registration Page and Fil the Details

Validates the Details

Success Message

Sequence Diagram for Vehicle Registration

Page 13: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

13

Fig 3.3.5: Sequence diagram for Vehicle Tracking

Admin

Vehicle Tollgate Owner Account

Vehicle enters into Tollgate

Reads RFID Tag

Passes Tag Information to Admin

Amount will be deducted

Success Message

Allow the Vehicle to pass

Sequence Diagram for Tracking the Vehicle

Page 14: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

14

Fig 3.3.6: Sequence diagram for No Parking Zone

Admin

Vehicle No Parking

Zone

Owner Account

Park in No Parkingzone

Reads the RFID Tag

Send Tag Information

Penality Amount will be deducted

Sequence Diagram for No Parkingzone

Page 15: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

15

Fig 3.3.7: Sequence diagram for Vehicle Complaint

Owner

Admin

Vehicle TollgateDatabase

Gives Complaint

Enter Details

Success

Details will be stored

Vehicle Enters to the Tollgate

Reads the RFID Tag

Verifies in the Vehicle details

Send Message

Pass the information to stop the vehicle

Stops the vehicle

Sequence Diagram for Theft Vehicle Complaint

Page 16: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

16

3.4 Collaboration Diagrams

A collaboration diagrams belongs to a group of UML diagrams called interaction

diagrams. Collaboration diagrams, like sequence diagrams, show how objects interact over the

course of time. However ,instead of showing the sequence by numbering the messages of the

diagram. This makes it easier to show how the objects are linked together ,but harder to see the

sequence at a glance.

Fig 3.4: Collaboration diagram

Page 17: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

17

3.5 Activity Diagram:

An activity diagram describes the behavior of the system in terms of its activities. These

activities are modeling an element that represent the execution of set of operations.These

are similar to flow chart diagrams.

Fig 3.5:Activity diagram

Page 18: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

18

3.6 Class diagram:

A class is a group of things that have similar attributes and common behaviors. Class

diagrams are used to describe the structure of the system. Objects are instances of classes that are

created, modified, and destroyed during the execution of the system. An object has state that

includes the values of its attributes and it links with other objects.

Fig 3.6:Class diagram

Page 19: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

19

3.7 DB Specification:

User info

Table 3.7.1: User info

Name Type Constraint

User ID Number Primary key

Owner Name Varchar2(20)

Gender Varchar2(20)

Date of birth Date

Mobile number Number

Email Id Varchar2(20)

Address Varchar2(20)

Image blob

City Id Number Foreign key

N-Id Number Foreign key

Page 20: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

20

City Table

Name Type Constraint

City ID Number Primary key

City Name Varchar2(20)

S Id Number Foreign key

Table 3.7.2: City Table

State Table

Name Type Constraint

S ID Number Primary key

State Name Varchar2(20)

C Id Number Foreign key

Table 3.7.3: State Table

Country Table

Name Type Constraint

C ID Number Primary key

Country Name Varchar2(20)

Table 3.7.4: Country Table

Page 21: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

21

Nationality Table

Name Type Constraint

N ID Number Primary key

Nationality Varchar2(20)

Table 3.7.5: Nationality Table

Highway Table

Name Type Constraint

Highway Name Varchar2(40) Primary key

Table 3.7.6: Highway Table

Tollgate Table

Name Type Constraint

Tollgate ID Number Primary key

Tollgate Name Varchar2(40)

Highway Name Varchar2(40) Foreign key

Table 3.7.7: Tollgate Table

Page 22: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

22

Vehicle Type_Tollgate Table

Name Type Constraint

VT ID Number PF key

Tollgate ID Number PF key

Amount ID Number Foreign key

Table 3.7.8: Vehicle Type_Tollgate Table

Vehicle Table

Name Type Constraint

Vehicletag ID Number Primary key

Vehicle number Number

RC number Number

Date of Registration Date

VT ID Number Foreign key

User ID Number Foreign key

Table 3.7.9: Vehicle Table

Page 23: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

23

Tracking Table

Name Type Constraint

Trac ID Number Primary key

Trackeddate Date

Track_time Varchar2(20)

Vehicletag ID Number PF key

Tollgate ID Number PF key

Remng amt Number

Amount deducted Number

Complaint ID Number Foreign key

Table 3.7.10: Tracking Table

Page 24: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

24

Complaint Table

Name Type Constraint

Complaint ID Number Primary key

Complaint date Date

Vehiclelost date Date

Description Varchar2(100)

Status of Complaint Varchar2(40)

Vehicletag ID Number Foreign key

Owner name Varchar2(40)

Table 3.7.11: Complaint Table

Account Table

Name Type Constraint

Acc ID Number Primary key

Amount deposited Number

Account type Id Number Foreign key

User ID Number Foreign key

Table 3.7.12: Account Table

Page 25: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

25

Vehicle Recharge Table

Name Type Constraint

RC ID Number Primary key

Date of RC Date

RC Amt Number

Avail amt Number

Acc ID Number Foreign key

Table 3.7.13: Vehicle Recharge Table

Vehicle type Table

Name Type Constraint

VT ID Number Primary key

Name Varchar2(40)

Table 3.7.14: Vehicle type Table

Account type Table

Name Type Constraint

Account type ID Number Primary key

Account type Varchar2(40)

Table 3.7.15: Account type Table

Page 26: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

26

Amount Table

Name Type Constraint

Amount ID Number Primary key

Fare Number

Table 3.7.16: Amount table

Page 27: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

27

CHAPTER-4

TECHNLOGY OVERVIEW

Automatic Identification and Data Capture:

(AIDC) refers to the methods of automatically identifying objects, collecting all data about them,

and entering that data directly into computer systems (i.e. without human involvement).

Technologies considered as part of AIDC include:

Bar codes

Radio Frequency Identification (RFID)

Biometrics

Magnetic stripes,

Optical Character Recognition (OCR),

Smart cards

Voice recognition.

AIDC is also commonly referred to as “Automatic Identification”,

“Auto-ID”, and "Automatic Data Capture".

Page 28: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

28

4. RFID:

Radio-frequency identification (RFID) is the use of a wireless non-contact system that uses

radio-frequency electromagnetic fields to transfer data from a tag attached to an object, for the

purposes of automatic identification and tracking. Some tags require no battery and are powered

by the electromagnetic fields used to read them. Others use a local power source and emit radio

waves(electromagnetic radiation at radio frequencies). The tag contains electronically stored

information which can be read from up to several meters (yards) away.

The RFID tag can be affixed to an object and used to track and manage inventory, assets, people,

etc. For example, it can be affixed to cars, computer equipment, books, mobile phones, etc.

RFID has gained the status of a universal standard in auto identification and is being touted

amongst the top ten inventions of20th century.

4.1 What is RFID?

To understand RFID, let us look at a similar technology, we are already familiar with –

Barcodes.

We see the usage of bar codes in many spheres of our day to day life. From products in super

markets to books in library, from identity cards to laptops and gadgets, almost everywhere.

Barcodes need Line of Sight (direct interface of optical barcode reader and barcode tag within a

conical angle of 120 degree without any obstacles).

RFID readers on the other hand can read RFID tags in omni direction(360 degree) and with

obstacles in between.

Barcode Readers can only read one tag at a time, where as RFID readers can read multiple tags

at a time in parallel.

Barcode tags are paper based tags and hence cannot be overwritten,(the information once written

cannot be changed). Rfid tags on the other hand are electronic tags that store information. The

information can be updated or locked(not allowed to update) based on application usage.

Page 29: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

29

Fig 4: RFID Technology

Page 30: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

30

4.1.1 RFID (v/s) Barcode:

RFID Barcode

Line of Site Not required (in most cases) Required

Read Range Passive UHF RFID:

- Up to 40 feet (fixed readers)

- Up to 20 feet (handheld readers)

Active RFID:

- Up to 100's of feet or more

Several inches up to several feet

Read Rate 10's, 100's or 1000's simultaneously Only one at a time

Identification Can uniquely identify each item/asset

tagged.

Most barcodes only identify the

type of item (UPC Code) but not

uniquely.

Read/Write Many RFID tags are Read/Write Read only

Technology RF (Radio Frequency) Optical (Laser)

Interference Like the TSA (Transportation

Security Administration), some

RFID frequencies don't like Metal

and Liquids. They can interfere with

some RF Frequencies.

Obstructed barcodes cannot be read

(dirt covering barcode, torn

barcode, etc.)

Automation Most "fixed" readers don't require

human involement to collect data

(automated)

Most barcode scanners require a

human to operate (labor intensive)

Page 31: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

31

4.1.2 Types of RFID Tags:

RFID tags come in three general varieties:

Passive

Active

Semi-passive (also known as battery-assisted).

Passive tags require no internal power source they are only active when a reader is nearby to

power them. The information from passive RFID tags is read by using the power of reader.

Semi-passive and Active tags require a power source, usually a small battery. Active RFID tags

can announce (pass) information on their own to the reader.

4.1.2.1 Active Tags (v/s) Passive Tags:

4.3.2 RFID Tags and Readers:

Page 32: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

32

RFID tags and readers come in different shapes and sized based on the application need.

The tags can be in the shape of a sticker, coin or chip in card.

The readers can be handheld or can be in the shape of gates at entryand exit points.

The RFID tag can be affixed to an object and used to track and manage inventory, assets, people,

etc. For example, it can be affixed to cars, computer equipment, books, mobile phones, etc. RFID

offers advantages over manual systems or use of bar codes. The tag can be read if passed near a

reader, even if it is covered by the object or not visible. The tag can be read inside a case, carton,

box or other container, and unlike barcodes, RFID tags can be read hundreds at a time. Bar codes

can only be read one at a time.

Page 33: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

33

In 2011, the cost of passive tags started at US$0.05 each; special tags, meant to be mounted on

metal or withstand gamma sterilization, can go up to US$5. Active tags for tracking containers,

medical assets, or monitoring environmental conditions in datacenters start at US$50 and can go

up over US$100 each. Battery Assisted Passive (BAP) tags are in the US$3–10 range and also

have sensor capability like temperature and humidity

4.1.3 RFID Frequency Bands:

4.1.3.1 Frequency and bandwidth:

• Frequency is of primary importance when determining data transfer rates(bandwidth).

• The higher the frequency, the higher the data transfer rate.

4.1.3.2 Frequency Bands and Tag Cost:

4.1.4 RFID - Replacement or Complement to barcode

RFID tags are often a complement, but not a substitute, for UPC or EAN barcodes. They may

never completely replace barcodes, due in part to their higher cost and the advantage of multiple

data sources on the same object. Also, unlike RFID labels, barcodes can be generated and

distributed electronically, e.g. via e-mail or mobile phone, for printing or display by the

recipient. An example is airline boarding passes. The new EPC, along with several other

schemes, is widely available at reasonable cost. The storage of data associated with tracking

items will require many terabytes. Filtering and categorizing RFID data is needed to create

Page 34: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

34

useful information. It is likely that goods will be tracked by the pallet using RFID tags, and at

package level with Universal Product Code(UPC) or EAN from unique barcodes.

The unique identity is a mandatory requirement for RFID tags, despite special choice of the

numbering scheme. RFID tag data capacity is large enough that each individual tag will have a

unique code, while current bar codes are limited to a single type code for a particular product.

The uniqueness of RFID tags means that a product may be tracked as it moves from location to

location, finally ending up in the consumer's hands. This may help to combat theft and other

forms of product loss. The tracing of products is an important feature that gets well supported

with RFID tags containing a unique identity of the tag and also the serial number of the object.

This may help companies cope with quality deficiencies and resulting recall campaigns, but also

contributes to concern about tracking and profiling of consumers after the sale. It has also been

proposed to use RFID for POS store checkout to replace the cashier with an automatic system

which needs no barcode scanning. In the past this was not possible due to the higher cost of tags

and existing POS process technologies. However ,Industry Standard, a couture shop and

recording studio in Ohio has successfully implemented a POS procedure that allows faster

transaction throughput.

An FDA-nominated task force concluded, after studying the various technologies currently

commercially available, which of those technologies could meet the pedigree requirements.

Amongst all technologies studied including bar coding, RFID seemed to be the most promising

and the committee felt that the pedigree requirement could be met by easily leveraging

something that is readily available.

This may help companies cope with quality deficiencies and resulting recall campaigns, but also

contributes to concern about tracking and profiling of consumers after the sale. It has also been

proposed to use RFID for POS store checkout to replace the cashier with an automatic system

which needs no barcode scanning. In the past this was not possible due to the higher cost of tags

studied including bar coding, RFID seemed to be the most promising and the committee felt that

the pedigree requirement could be met by easily leveraging something that is readily available.

but also contributes to concern about tracking and profiling of consumers after the sale. It has

also been

Page 35: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

35

4.1.5 RFID System Architecture:

Fig 4.1.5: RFID Architecture

4.1.5.1 How Does RFID Works??

RFID methods utilize radio waves to accomplish this. At a simple level, RFID systems consist of

three components:

RFID tag or smart label

Page 36: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

36

RFID reader

Antenna.

RFID tags contain an integrated circuit and an antenna, which is used to transmit data to the

RFID reader (also called an interrogator).The reader then converts the radio waves to a more

usable form of data. Information collected from the tags is then transferred through a

communications interface to a host computer system, where the data can be stored in a database

and analyzed at a later time.

4.6.2 Electronic Product Code:

The Electronic Product Code (EPC) is designed as a universal identifier that provides a unique

identity for every physical object anywhere in the world, for all time.

4.1.6 EVOLUTION OF RFID:

"In retail, RFID is seeing rapid growth for apparel tagging. RFID in the form of tickets used for

transit will demand 450 million tags in 2011.The tagging of animals (such as pigs, sheep and

pets) is now substantial as it becomes a legal requirement in many more territories, with 243

million tags being used for this sector in 2011.

This is happening in regions such as China and Australia. In total, 2.88billion tags will be sold in

2011 versus 2.31 billion in 2010. Most of that growth is from passive UHF RFID labels."

4.2 Application areas where RFID is used:

RFID can be used in a variety of applications, such as:

Access management

Page 37: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

37

Tracking of goods

Tracking of persons and animals

Toll collection and contactless payment

Machine readable travel documents

Smart dust (for massively distributed sensor networks)

Tracking sports memorabilia to verify authenticity

Airport baggage tracking logistics.

In 2010 three key factors drove a significant increase in RFID usage: decreased cost of

equipment and tags, increased performance to a reliability of 99.9%and a stable international

standard around UHF passive RFID.

At RFID Journal Live 2010 in Orlando, Airbus detailed 16 active projects, IBM and—most

recently added to the team—CSC.

The two other areas of significant use are financial services for IT asset tracking and healthcare.

RFID is becoming increasingly prevalent as the price of the technology decreases.

RFID combined with mobile computing and Web technologies provide away for organizations to

identify and manage their assets.

4.2.1 Asset management:

Mobile computers, with integrated RFID readers, can now deliver a complete set of tools that

eliminate paperwork, give proof of identification and attendance.

This approach eliminates manual data entry .Web based management tools allow organizations

to monitor their assets and make management decisions from anywhere in the world. Web based

applications now mean that third parties, such as manufacturers and contractors can be granted

access to update asset data, including for example, inspection history and transfer documentation

online ensuring that the end user always has accurate, real-time data.

Organizations are already using RFID tags combined with a mobile asset management solution

to record and monitor the location of their assets, their current status, and whether they have been

maintained. RFID is being adopted for item-level retail uses. Aside from efficiency and product

availability gains, the system offers a superior form of electronic article surveillance (EAS), and

a superior.

Page 38: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

38

RFID is being adopted for item-level retail uses. Aside from efficiency and product availability

gains, the system offers a superior form of electronic article surveillance (EAS), and a superior

self checkout process for consumers.

The first commercial, public item-level RFID retail system installation is believed to be in May

2005 by Freedom Shopping, Inc. in North Carolina,USA.2009 witnessed the beginning of wide-

scale asset tracking with passive

RFID. Wells Fargo and Bank of America made announcements that they would track every item

in their data centers using passive RFID.

Most of the leading banks have since followed suit. The Financial Services Technology

Consortium (FSTC) set a technical standard for tagging IT assets and other industries have used

that standard as a guideline.

For instance the US State Department is now tagging IT assets with passive RFID using the

ISO/IEC 18000-6 standard.

4.2.1.1 Inventory systems:

An advanced automatic identification technology based on RFID technology has significant

value for inventory systems. The system can provide accurate knowledge of the current

inventory.

In an academic study performed at Wal-Mart, RFID reduced Out-of-Stocks by 30 percent for

products selling between 0.1 and 15 units a day. Other benefits of using RFID include the

reduction of labor costs, the simplification of business processes, and the reduction of inventory

inaccuracies.

In 2004, Boeing integrated the use of RFID technology to help reduce maintenance and

inventory costs on the Boeing 787 Dream liner. With the high costs of aircraft parts, RFID

technology allowed Boeing to keep track of inventory despite the unique sizes, shapes and

environmental concerns.

During the first six months after integration, the company was able to save$29,000 in labor.

Page 39: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

39

In 2007, Recall Corporation integrated the use of RFID to help organizations track and audit

their records, to support compliance with regulations such as the Sarbanes-Oxley Act and

HIPAA.

CASE STUDIES

4.2.1.2 Product tracking

RFID use in product tracking applications begins with plant-based production processes, and

then extends into post-sales configuration management policies for large buyers .In 2005, the

Wynn Casino, Las Vegas, began placing individual RFID tags on high value chips.

These tags allowed casinos the ability to detect counterfeit chips, track betting habits of

individual players, speed up chip tallies, and determine counting mistakes of dealers.

In 2010, the Bellagio casino was robbed of $1.50 million in chips. The RFID tags of these chips

were immediately invalidated, thus making the cash value of these chips $0.RFID can also be

used for supply chain management in the fashion industry.

The RFID label is attached to the garment at production, can be read /traced throughout the

entire supply chain and is removed at the point of sale (POS).

4.2.1.3 Access control

High-frequency tags are widely used in identification badges, replacing earlier magnetic stripe

cards. These badges need only be held within a certain distance of the reader to authenticate the

holder. The American Express Blue credit card now includes a High FID tag. In Feb 2008,

Emirates Airline started a trial of RFID baggage tracing at London and Dubai airports.

4.2.1.4 Promotion tracking

To prevent retailers diverting products, manufacturers are exploring the use of RFID tags on

promoted merchandise so that they can track exactly which product has sold through the supply

chain at fully discounted prices.

Logistics and transportation are major areas of implementation for RFID technology.Yard

management, shipping and freight and distribution centers use RFID tracking technology. In the

Page 40: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

40

railroad industry, RFID tags mounted on locomotives and rollingstock identify the owner,

identification number and type of equipment and its characteristics. This can be used with a

database to identify the lading, origin, destination, etc. of the commodities being carried

.4.2.2.1 Transportation and logistics

In commercial aviation, RFID technology is being incorporated to support maintenance on

commercial aircraft. RFID tags are used to identify baggage and cargo at several airports and

airlines. Some countries are using RFID technology for vehicle registration and enforcement.

RFID can help detect and retrieve stolen cars.

4.2.2.2 Infrastructure management and protection

At least one company has introduced RFID technology to identify and locate underground

infrastructure assets such as gas pipelines, sewer lines, electrical cables, communication cables,

etc.

4.2.2.3 Transportation payments

In many countries, RFID tags can be used to pay for mass transit fares on bus, trains, or subways,

or to collect tolls on highways. Some bike lockers are operated with RFID cards.

A prepaid card is required to open or enter a facility or locker and is used to track and charge

based on how long the bike is parked.

4.2.3.1 Identification

Main articles: Microchip implant (animal) and Microchip implant (human)

Fig 4.2.3.1: RFID Technology Identification

Page 41: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

41

Animal management using RFID technology. Santa Gertrudis cattle: The calf has an electronic

ear tag and herd management tag (yellow).

RFID tags for animals represent one of the oldest uses of RFID technology. Originally meant for

large ranches and rough terrain, since the outbreak of mad-cow disease, RFID has become

crucial in animal identification management.

An implantable RFID tag or transponder can also be used for animal identification. The

transponders are more well-known as passive RFID technology, or "chips" on animals.

The Canadian Cattle Identification Agency began using RFID tags as are placement for barcode

tags. Currently CCIA tags are used in Wisconsin and by US farmers on a voluntary basis.

The USDA is currently developing its own program Implantable RFID chips designed for animal

tagging are now being used in humans.

An early experiment with RFID implants was conducted by British professor of cybernetics

Kevin Warwick, who implanted a chip in his arm in1998.

In 2004 Conrad Chase offered implanted chips in his night clubs in Barcelona and Rotterdam to

identify their VIP customers, who in turn use it to pay for drinks.

Privacy advocates have protested against implantable RFID chips, warning of potential abuse.

4.2.3.2 Hospitals and healthcare

Adoption of RFID in the medical industry has been widespread and very effective. Hospitals are

among the first users to combine both active and passive RFID technology.

Many successful deployments in the healthcare industry have been cited where active technology

tracks high-value, or frequently moved items, where passive technology tracks smaller, lower

cost items that only need room-level identification. The trend is toward using ISO 18000-6c as

the tag of choice and combining an active tagging system that relies on existing 802.11X

wireless infrastructure for active tags.

Since 2004 a number of U.S. hospitals have begun implanting patients with RFID tags and using

RFID systems, usually for workflow and inventory management.

Page 42: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

42

The use of RFID to prevent mix ups between sperm and ova in IVF clinics is also being

considered. In October 2004, the FDA approved USA's first RFID chips that can be implanted in

humans.

The 134 kHz RFID chips, from VeriChip Corp. can incorporate personal medical information

and could save lives and limit injuries from errors in medical treatments, according to the

company. Anti-RFID activists

According to the FDA, these include "adverse tissue reaction", "migration of the implanted

transponder", "failure of implanted transponder", "electrical hazards" and "magnetic resonance

imaging [MRI] incompatibility."

4.2.3.3 Libraries

RFID tags used in libraries: square book tag, round CD/DVD tag and rectangular VHS tag.

Libraries have used RFID to replace the barcodes on library items. The tag can contain

identifying information or may just be a key into a database. An RFID system may replace or

supplement bar codes and may offer another method of inventory management and self-service

checkout by patrons. It can also act as a security device, taking the place of the more traditional

electromagnetic security strip.

It is estimated that over 30 million library items worldwide now contain Since RFID tags can be

read through an item, there is no need to open a book cover or DVD case to scan an item, and a

stack of books can be read simultaneously.

Book tags can be read while books are in motion on a conveyor belt, which reduces staff time.

This can all be done by the borrowers themselves, reducing the need for library staff assistance.

With portable readers, inventories could be done on a whole shelf of materials within seconds.

However, as of 2008 this technology remains too costly for many smaller libraries, and the

conversion period has been estimated at 11 months for an average-size library.

A 2004 Dutch estimate was that a library which lends 100,000 books per year should plan on a

cost of €50,000 (borrow- and return-stations: 12,500each, detection porches 10,000 each; tags

0.36 each). RFID taking a large burden off staff could also mean that fewer staff will be needed,

Page 43: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

43

resulting in some of them getting fired, but that has so far not happened in North America where

recent surveys have not returned a single library that cut staff because of adding RFID.

In fact, library budgets are being reduced for personnel and increased for infrastructure, making

it necessary for libraries to add automation to compensate for the reduced staff size. Also, the

tasks that RFID takes over are largely not the primary tasks of librarians.

finding in the Netherlands is that borrowers are pleased with the fact that staff are now more

available for answering questions . A concern surrounding RFID in issue of privacy. Because

some RFID tag scan be read from up to 100 meters (330 ft), there is some concern over whether

sensitive information could be collected from an unwilling source.

However, library RFID tags do not contain any patron information, and the tags used in the

majority of libraries use a frequency only readable from approximately 10 feet (3.0 m).

Further, another non-library agency could potentially record the RFID tags of every person

leaving the library without the library administrator's knowledge or consent.

One simple option is to let the book transmit a code that has meaning only in conjunction with

the library's database. Another step further is to give the book a new code every time it is

returned. And if in the future readers become ubiquitous (and possibly networked), then stolen

books could be traced even outside the library. Tag removal could be made difficult if the tags

are so small that they fit in visibly inside a (random) page, possibly put there by the publisher.

4.2.3.4 Museums

RFID technologies are now also implemented in end-user applications in museums .An example

was the custom-designed temporary research application, "eXspot," at the Exploratorium, a

science museum in San Francisco, California .A visitor entering the museum received an RF Tag

that could be carried as a card.

The eXspot system enabled the visitor to receive information about specific exhibits. Aside from

the exhibit information, the visitor could take photographs of themselves at the exhibit. It was

also intended to allow the visitor to take data for later analysis.The collected information could

be retrieved at home from a "personalized" website keyed to the RFID tag.

Page 44: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

44

4.2.3.5 Schools and universities

School authorities in the Japanese city of Osaka are now chipping children's clothing, back

packs, and student IDs in a primary school .A school in Doncaster, England is piloting a

monitoring system designed to keep tabs on pupils by tracking radio chips in their uniforms. St

Charles Sixth Form College in west London, England, started September, 2008, is using an RFID

card system to check in and out of the main gate, to both track attendance and prevent

unauthorized entrance. Similarly, Whitcliffe Mount School in Cleckheaton, England uses RFID

to track pupils and staff in and out of the building via a specially designed card.

In the Philippines, some schools already use RFID in IDs for borrowing books and also gates in

those particular schools have RFID ID scanners for buying items at a school shop and canteen,

library and also to sign in and sign out for student and teacher's attendance. A school in

Doncaster, England is piloting a monitoring system designed to keep tabs on pupils by tracking

radio chips in their uniforms. St Charles Sixth Form College in west London, England, started

September, 2008, is using an RFID card system

4.2.3.6 Sports

Champion Chip:

RFID for timing races began in the early 1990s with pigeon racing, introduced by the company

Deister Electronics in Germany .RFID can provide race start and end timings for individuals in

large races where it is impossible to get accurate stopwatch readings for every entrant.

In the race, the racers wear tags that are read by antennae placed along side the track or on mats

across the track.UHF tags provide accurate readings with specially designed antennas. Rusherror,

lap count errors and accidents at start time are avoided since anyone can start and finish any time

without being in a batch mode.

Passive and active RFID systems are used in off-road events such as Orienteering, Enduro and

Hare and Hounds racing. Riders have a transponder on their person, normally on their arm.

When they complete a lap they swipe or touch the receiver which is connected to a computer and

log their lap time. RFID is being adapted by many recruitment agencies which have a

Page 45: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

45

PET(Physical Endurance Test) as their qualifying procedure especially in cases where the

candidate volumes may run into millions (Indian Railway Recruitment Cells, Police and Power

sector).

A number of ski resorts have adopted RFID tags to provide skiers hands-free access to ski lifts.

Skiers do not have to take their passes out of their pockets. Early on skiers were forced to use

systems that required nearly contact - bending over to touch the turn styles .These systems were

based on high frequency (HF) at 13.56 megahertz .While effective at tracking the skiers they

were difficult to use and expensive to deploy. However the bulk of ski areas in Europe, from

Verbier to Chamonix use these systems.

4.2.3.7 Telemetry

Active RFID tags also have the potential to function as low-cost remote sensors that broadcast

telemetry back to a base station. Applications of tagometry data could include sensing of road

conditions by implanted beacons, weather reports, and noise level monitoring. Passive RFID tags

can also report sensor data. For example, the Wireless Identification and Sensing Platform is a

passive tag that reports temperature, acceleration and capacitance to commercial Gen2 RFID

readers. It is possible that active or battery assisted passive (BAP) RFID tags, used with or in

place of barcodes, could broadcast a signal to an in-store receiver to determine whether the RFID

tag (product) is in the store.

4.3 Eclipse

Eclipse is a multi-language software development environment comprising a base workspace

and an extensible plug-in system for customizing the environment. It is written mostly in java.It

can be used to develop applications in Java and, by means of various plug-ins, even other

languages including Ada, C, C++, COBOL, Fortran, Haskell, JavaScript, Perl, PHP, Python,

Scala , Clojure, Groovy, Scheme, and Erlang. It can also be used to develop packages for the

software Mathematica. Development environments include the Eclipse Java development tools

(JDT) for Java and Scala, Eclipse CDT for C/C++ and Eclipse PDT for PHP, among others.The

initial codebase originated from IBM Visual Age. The Eclipse software development kit,which

includes the Java development tools, is meant for Java developers. Users can extend its abilities

by installing plug-ins written for the Eclipse Platform, such as to development tool kits for other

Page 46: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

46

programming languages, and can write and contribute their own plug-in modules Released under

the terms of the Eclipse Public License, Eclipse SDK is free and open source software .It was

one of the first IDEs to run under GNU Class path and it runs without problems under IcedTea.

4.4 Oracle10g

The Oracle RDBMS stores data logically in the form of table spaces and physically in the form

of data files ("datafiles"). Table spaces can contain various types of memory segments, such as to

Data Segments, Index Segments, etc. Segments in turn comprise one or more extents. Extents a

comprise groups of contiguous data blocks. Data blocks form the basic units of data storage.

Newer versions of the database can also include a partitioning feature: this allows the

partitioning of tables based on different set of keys . Specific partitions can then be easily added

or dropped to help manage large data sets. Partitioning is useful for very large tables. By splitting

a large table’s rows across multiple smaller partitions, you accomplish several important goals:

Backup and recovery operations may perform better. Because the partitions are smaller than

the partitioned table, you may have more options for backing up and recovering the

partitions than you would have for a single large table

The table may be easier to manage. Because the partitioned table’s data is stored in multiple

parts, it may be easier to load and delete data in the partitions than in the large table.

The performance of queries against the tables may improve because Oracle may have to

search only one partition (one part of the table) instead of the entire table to resolve a query.

Oracle database management tracks its computer data storage with the help of information stored

in the SYSTEM tablespace. TheSYSTEM tablespace contains the data dictionary—and often (by

default) indexes and clusters. A data dictionary consists of a special collection of tables that will

contains information about all user-objects in the database. Since version 8i, the Oracle RDBMS

also supports "locally managed" tablespaces which can store space management information in a

bitmaps in their own headers rather than in the SYSTEM tablespace (as happens with the default

"dictionary-managed" tablespaces). Version 10g and later introduced the SYSAUXtablespace in

Page 47: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

47

which contains some of the tables formerly in the SYSTEM tablespace.

Most Oracle database installations traditionally came with a default schema called SCOTT.

After the installation process has set up the sample tables, the user can log into the database with

the username scott and the password tiger.

Oracle Corporation has to de-emphasized the use of the SCOTT schema, as it uses the few of the

features of the more recent releases of Oracle. Most recent examples supplied by Oracle

Corporation reference the default HR or OE schemas.

Other default schemas include:

SYS (essential core database structures and utilities)

SYSTEM (additional core database structures and utilities, and privileged account)

OUTLN (utilized to store metadata for stored outlines for stable query-optimizer execution

plans.

BI, IX, HR, OE, PM, and SH (expanded sample schemas containing more data and structures

than the older SCOTT schema).

Page 48: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

48

CHAPTER-5

CODING

5.1 Connection Database

import java.awt.Image;

import java.io.BufferedInputStream;

import java.io.File;

import java.io.FileInputStream;

import java.io.FileNotFoundException;

import java.io.IOException;

import java.io.InputStream;

import java.sql.Blob;

import java.sql.Connection;

import java.sql.DriverManager;

import java.sql.PreparedStatement;

import java.sql.ResultSet;

import java.sql.SQLException;

import java.sql.Statement;

import java.util.ArrayList;

import javax.imageio.ImageIO;

import javax.swing.JOptionPane;

public class ConnectionDataBase {

Connection con=null;

Statement st=null;

ResultSet rs=null;

ResultSet rs1=null;

PreparedStatement ps=null;

FileInputStream fis=null;

File file;

public void createConnection()

{

try {

Class.forName("oracle.jdbc.driver.OracleDriver");

System.out.println("class is loaded");

con=DriverManager.getConnection("jdbc:oracle:thin:@localhost:152

1:XE","tollgate","idealabs");

System.out.println("the connection is created");

st=con.createStatement();

} catch (ClassNotFoundException e) {

Page 49: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

49

// TODO Auto-generated catch block

e.printStackTrace();

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

}

public ArrayList getCountryInfo()

{

ArrayList countrylist=new ArrayList();

try {

st=con.createStatement();

String getcountry="select name from country";

rs=st.executeQuery(getcountry);

while(rs.next())

{

countrylist.add(rs.getString(1));

System.out.println(":::::::::::"

+countrylist);

}

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

return countrylist;

}

public ArrayList getStatusInfo()

{

ArrayList statuslist=new ArrayList();

try {

st=con.createStatement();

String getstatus="select status from status";

rs=st.executeQuery(getstatus);

while(rs.next())

{

statuslist.add(rs.getString(1));

System.out.println(":::::::::::"

+statuslist);

}

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

return statuslist;

}

Page 50: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

50

public ArrayList getStatelist(String country)

{

String statname=null;

ArrayList statelist=new ArrayList();

try {

int cid = 0;

st=con.createStatement();

String getcntryid="select c_id from country where

name='"+country+"'";

System.out.println(getcntryid);

rs=st.executeQuery(getcntryid);

while(rs.next())

{

cid=rs.getInt(1);

System.out.println(":::::::::::::::::::"+cid);

}

String statevalue="select name from state where

c_id='"+cid+"'";

rs=st.executeQuery(statevalue);

while(rs.next())

{

statname=rs.getString(1);

statelist.add(statname);

System.out.println(statname);

}

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

return statelist;

}

public ArrayList getCityInfo(String state)

{

int sid=0;

String city=null;

ArrayList citylist=new ArrayList();

try {

st=con.createStatement();

String getstateid="select s_id from state where

name='"+state+"'";

System.out.println(getstateid);

Page 51: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

51

rs=st.executeQuery(getstateid);

while(rs.next())

{

sid=rs.getInt(1);

System.out.println("::::::::"+sid);

}

String cityname="select name from city where

S_id='"+sid+"'";

rs=st.executeQuery(cityname);

while(rs.next())

{

city=rs.getString(1);

citylist.add(city);

System.out.println(city);

}

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

return citylist;

}

public ArrayList getNationalityInfo()

{

ArrayList Nationalitylist=new ArrayList();

try {

st=con.createStatement();

String getnationality="select nationality from

nationality";

rs=st.executeQuery(getnationality);

while(rs.next())

{

Nationalitylist.add(rs.getString(1));

System.out.println(":::::::::::"

+Nationalitylist);

}

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

return Nationalitylist;

}

Page 52: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

52

public void userDetails(int id, String firstname, String

gender, String DOB, String mobilenumber,String path, String

email, String address, String cityname, String Nname)

{

int mobile;

//ArrayList city=new ArrayList();

//ArrayList natio=new ArrayList();

String city = null;

int natio=0;

mobile=Integer.parseInt(mobilenumber);

file=new File(path);

try {

fis=new FileInputStream(file);

} catch (FileNotFoundException e1) {

// TODO Auto-generated catch block

e1.printStackTrace();

}

try {

st=con.createStatement();

ps=con.prepareStatement(path);

String cityid="select city_id from city where

name='"+cityname+"'";

rs=st.executeQuery(cityid);

while(rs.next())

{

city=rs.getString(1);

System.out.println(":::::::::::" +city);

}

//String date="12-feb-2012";

String nid="select n_id from nationality where

nationality='"+Nname+"'";

rs1=st.executeQuery(nid);

while(rs.next())

{

natio=rs.getInt(1);

System.out.println(":::::::::::" +natio);

}

String userdetails="insert into

USERINFO(USER_ID,OWNER_NAME,GENDER,DATE_OF_BIRTH,MOBILE_NUMBER,E

MAIL_ID,ADDRESS,CITY_ID,N_ID)

values('"+id+"','"+firstname+"','"+gender+"','"+DOB+"','"+mobile

+"','"+email+"','"+address+"','"+city+"','"+natio+"')";

st.executeUpdate(userdetails);

} catch (SQLException e) {

// TODO Auto-generated catch block

Page 53: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

53

e.printStackTrace();

}

}

public int userDetailsImage(int id, String name, String

gender, String DOB, int mn,String path, String email, String

address, String cityname, String Nname)

{

int i=0;

//int mobile=0;

//ArrayList city=new ArrayList();

//ArrayList natio=new ArrayList();

String city = null;

int natio=0;

//mobile=Integer.parseInt(mobilenumber);

file=new File(path);

try {

fis=new FileInputStream(file);

} catch (FileNotFoundException e1) {

// TODO Auto-generated catch block

e1.printStackTrace();

}

try {

st=con.createStatement();

//ps=con.prepareStatement(path);

String cityid="select city_id from city where

name='"+cityname+"'";

rs=st.executeQuery(cityid);

while(rs.next())

{

city=rs.getString(1);

System.out.println(":::::::::::" +city);

}

//String date="12-feb-2012";

String nid="select n_id from nationality where

nationality='"+Nname+"'";

System.out.println("::::::::::::::::::::::::::::::::::::

is"+nid);

rs=st.executeQuery(nid);

while(rs.next())

{

natio=rs.getInt(1);

System.out.println(":::::::::::" +natio);

}

String userdetails="insert into

USERINFO(USER_ID,OWNER_NAME,GENDER,DATE_OF_BIRTH,MOBILE_NUMBER,E

Page 54: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

54

MAIL_ID,IMAGE,ADDRESS,CITY_ID,N_ID)

values(?,?,?,?,?,?,?,?,?,?)";

ps=con.prepareStatement(userdetails);

ps.setInt(1,id);

ps.setString(2,name);

ps.setString(3,gender);

ps.setString(4, DOB);

ps.setInt(5,mn);

ps.setString(6, email);

ps.setBinaryStream(7, fis, (int) file.length());

ps.setString(8,address);

ps.setString(9,city);

ps.setInt(10,natio);

i= ps.executeUpdate();

System.out.println(i);

System.out.println(i);

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

return i;

}

public ArrayList getTypeOfVehicleInfo()

{

ArrayList typeofvehiclelist=new ArrayList();

try {

st=con.createStatement();

String gettypeofvehicle="select name from

VT";

rs=st.executeQuery(gettypeofvehicle);

while(rs.next())

{

typeofvehiclelist.add(rs.getString(1));

System.out.println(":::::::::::"

+typeofvehiclelist);

}

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

return typeofvehiclelist;

}

public ArrayList getTypeOfAccountInfo()

Page 55: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

55

{

ArrayList typeofaccountlist=new ArrayList();

try {

st=con.createStatement();

String gettypeofaccount="select ACCOUNTTYPE

from ACCOUNTTYPE";

rs=st.executeQuery(gettypeofaccount);

while(rs.next())

{

typeofaccountlist.add(rs.getString(1));

System.out.println(":::::::::::"

+typeofaccountlist);

}

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

return typeofaccountlist;

}

public ArrayList getHighwayInfo()

{

ArrayList highwaylist=new ArrayList();

try {

st=con.createStatement();

String highway="select highway_name from

highway";

rs=st.executeQuery(highway);

while(rs.next())

{

highwaylist.add(rs.getString(1));

System.out.println(":::::::::::"

+highwaylist);

}

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

return highwaylist;

}

public int admin(int id,String adminname,String

gender,String DOB,int mn,String address,String cityname)

{

int i=0;

int mobile=mn;

ArrayList city=new ArrayList();

Page 56: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

56

String city1 = null;

try {

st=con.createStatement();

String cityid="select city_id from city

where name='"+cityname+"'";

rs=st.executeQuery(cityid);

while(rs.next())

{

city1=rs.getString(1);

System.out.println(":::::::::::"

+city1);

}

String admindetails="insert into admin(

ADMIN_ID, ADMIN_NAME,GENDER,MOBILE_NUMBER,ADDRESS,CITY_ID,

DATE_OF_BIRTH

)values('"+id+"','"+adminname+"','"+gender+"','"+DOB+"','"+mobil

e+"','"+address+"','"+city1+"')";

i=st.executeUpdate(admindetails);

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

return i;

}

public int accountDetails(int id, int accid, String

accounttype,String amountdeposited)

{

// TODO Auto-generated method stub

int acc=0;

int i=0;

String account = null;

try {

st=con.createStatement();

String vid="select ACCTYPE_ID from ACCOUNTTYPE

where ACCOUNTTYPE='"+accounttype+"'";

System.out.println(vid);

rs=st.executeQuery(vid);

while(rs.next())

{

acc=rs.getInt(1);

System.out.println(":::::::::::" +acc);

}

String accdetails="insert into

account(ACC_ID,AMOUNT_DEPOSITED,ACCTYPE_ID,USER_ID

)values('"+accid+"','"+amountdeposited+"','"+acc+"',"+id+")";

i=st.executeUpdate(accdetails);

Page 57: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

57

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

return i;

}

public int vehicleRegistrationDetails(int id, String DOR,

String vehiclenumber, String vehicletagid, String

rcnumber,

String licencenum, String TOV) {

int acc=0;

int i=0;

// TODO Auto-generated method stub

try {

st=con.createStatement();

String vid="select VT_ID from VT where

name='"+TOV+"'";

//System.out.println(vid);

rs=st.executeQuery(vid);

while(rs.next())

{

acc=rs.getInt(1);

System.out.println(":::::::::::" +acc);

}

String accdetails="insert into

vehicle(VEHICLETAG_ID,VEHICLE_NUMBER,LICENSE_NUMBER,RC_NUMBER,DA

TE_OF_REG,VT_ID ,USER_ID

)values('"+vehicletagid+"','"+vehiclenumber+"','"+licencenum+"',

'"+rcnumber+"','"+DOR+"','"+acc+"','"+id+"')";

i= st.executeUpdate(accdetails);

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

return i;

}

public int TollgateID()

{

int a=0;

try {

st=con.createStatement();

} catch (SQLException e) {

// TODO Auto-generated catch block

Page 58: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

58

e.printStackTrace();

}

String query="select max(toll_id)+1 from toll";

try {

rs=st.executeQuery(query);

if(rs.next())

{

a=rs.getInt(1);

}

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

return a;

}

public int TracID()

{

int a=0;

try {

st=con.createStatement();

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

String query="select count(trac_id)+1 from tracking";

try {

rs=st.executeQuery(query);

if(rs.next())

{

a=rs.getInt(1);

}

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

return a;

}

public int tollgatereg(int id, String tollgatename, String

highway) {

// TODO Auto-generated method stub

int i=0;

Page 59: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

59

try{

st=con.createStatement();

String tolldetails="insert into

toll(TOLL_ID,TOLL_NAME,HW_NAME

)values('"+id+"','"+tollgatename+"','"+highway+"')";

i=st.executeUpdate(tolldetails);

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

return i;

}

public int tollgateregsetamount(int id, String tollname,

String vehicletype, int amt) {

// TODO Auto-generated method stub

int type=0;

int i=0;

// TODO Auto-generated method stub

try {

st=con.createStatement();

String vid="select VT_ID from VT where

name='"+vehicletype+"'";

//System.out.println(vid);

rs=st.executeQuery(vid);

while(rs.next())

{

type=rs.getInt(1);

System.out.println(":::::::::::" +type);

}

String details="insert into

VT_Toll(VT_ID,TOLL_ID,AMNT_ID)values('"+type+"','"+id+"','"+amt+

"')";

i= st.executeUpdate(details);

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

return i;

}

public void closeConnection() throws SQLException

{

rs.close();

//rs1.close();

st.close();

con.close();

Page 60: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

60

}

public ArrayList trackingdetails(String id) {

// TODO Auto-generated method stub

int trackuserid=0;

String vehiclenum=null;

String ownername=null;

int vtid=0;

int amountdeposited=0;

String trackamountdeduct=null;

ArrayList details=new ArrayList();

try {

st=con.createStatement();

String complianidetails="select vehicletag_id

from complaint where vehicletag_id='"+id+"'";

System.out.println(complianidetails);

rs=st.executeQuery(complianidetails);

if(rs.next())

{

JOptionPane.showMessageDialog(null, "vehicle

got stolen");

}

else

{

String track="select

s.user_id,s.owner_name,v.vehicle_number,v.VT_Id from userinfo

s,vehicle v where v.vehicletag_id='"+id+"' and

s.user_id=v.user_id";

System.out.println("the query

is:::::::::::"+track);

rs=st.executeQuery(track);

while(rs.next())

{

System.out.println("entered loop");

trackuserid=rs.getInt(1);

ownername=rs.getString(2);

vehiclenum=rs.getString(3);

vtid=rs.getInt(4);

System.out.println(":::::::::::"

+trackuserid);

}

String amountdepositedquery="select

a.amount_deposited from account a,userinfo s,vehicle v where

vehicletag_id='"+id+"' and s.user_id=a.user_id and

s.user_id=v.user_id ";

System.out.println("the query

is:::::::::::"+amountdepositedquery);

rs=st.executeQuery(amountdepositedquery);

Page 61: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

61

while(rs.next())

{

amountdeposited=rs.getInt(1);

}

String amountdeduction="select Amnt_id from

VT_Toll where VT_id='"+vtid+"' and Toll_id=7";

System.out.println(amountdeduction);

rs=st.executeQuery(amountdeduction);

while(rs.next())

{

trackamountdeduct=rs.getString(1);

}

int

trackamnt=Integer.parseInt(trackamountdeduct);

int remainingamount=amountdeposited-trackamnt;

//String updateamnt="update table account set

amount_deposited='"+remainingamount+"' ";

details.add(trackuserid);

details.add(ownername);

details.add(vehiclenum);

details.add(vtid);

System.out.println(details);

details.add(trackamountdeduct);

details.add(remainingamount);

//String details="select owner_name from userinfo

where user_id='"+trackuserid+"'";

String updateamnt="update account set

amount_deposited='"+remainingamount+"' where

user_id='"+trackuserid+"' ";

st.executeUpdate(updateamnt);

}

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

return details;

}

public int trackinsertdetails(String tracid, String date,

String time,

String id, String tollid, String remainingamount,

String amntdeducted) {

// TODO Auto-generated method stub

int i=0;

Page 62: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

62

try {

st=con.createStatement();

String tracdetails="insert into tracking(

TRAC_ID,TRACKEDDATE,TRACK_TIME,VEHICLETAG_ID,TOLLGATE_ID,REMNG_A

MNT,AMOUNT_DEDUCTED

)values('"+tracid+"','"+date+"','"+time+"','"+id+"','"+tollid+"'

,'"+remainingamount+"','"+amntdeducted+"')";

i= st.executeUpdate(tracdetails);

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

return i;

}

public int UserID() {

// TODO Auto-generated method stub

int a=0;

try {

st=con.createStatement();

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

String query="select count(user_id)+1 from userinfo";

try {

rs=st.executeQuery(query);

if(rs.next())

{

a=rs.getInt(1);

}

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

return a;

}

public int AdminID() {

// TODO Auto-generated method stub

int a=0;

Page 63: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

63

try {

st=con.createStatement();

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

String query="select count(admin_id)+1 from admin";

try {

rs=st.executeQuery(query);

if(rs.next())

{

a=rs.getInt(1);

}

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

return a;

}

public int ComplaintID() {

// TODO Auto-generated method stub

int a=0;

try {

st=con.createStatement();

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

String query="select count(COMPLAINT_ID)+1 from

complaint";

try {

rs=st.executeQuery(query);

if(rs.next())

{

a=rs.getInt(1);

}

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

Page 64: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

64

return a;

}

public int ComplaintDetails(String complaintID, String

complaintdate,

String vehiclelostdate, String description,

String status, String ownername,

String vehicletag) {

// TODO Auto-generated method stub

int i=0;

try {

st=con.createStatement();

String cmpdetails="insert into complaint(

COMPLAINT_ID,COMPLAINT_DATE,VEHLOST_DATE,DESCRIPTION,STATUS_OFCM

P,VEHICLETAG_ID,OWNER_NAME

)values('"+complaintID+"','"+complaintdate+"','"+vehiclelostdate

+"','"+description+"','"+status+"','"+vehicletag+"','"+ownername

+"')";

i= st.executeUpdate(cmpdetails);

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

return i;

}

public int rechargedetails(String rechargeid, String dor,

String availbleamnt, int amountdepo, String rechargeamnt, String

accntid) {

// TODO Auto-generated method stub

int i=0;

try {

st=con.createStatement();

String cmpdetails="insert into VEHICLE_RC_VEHICLE(

RC_ID,DATEOF_RC,RC_AMT,AVAIL_AMT,ACC_ID

)values('"+rechargeid+"','"+dor+"','"+rechargeamnt+"','"+availbl

eamnt+"','"+accntid+"')";

i= st.executeUpdate(cmpdetails);

String updateamnt="update account set

amount_deposited='"+amountdepo+"' where acc_id='"+accntid+"' ";

System.out.println(updateamnt);

st.executeUpdate(updateamnt);

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

return i;

}

Page 65: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

65

public int rechargeID() {

// TODO Auto-generated method stub

int a=0;

try {

st=con.createStatement();

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

String query="select count(rc_id)+1 from

VEHICLE_RC_VEHICLE";

try {

rs=st.executeQuery(query);

if(rs.next())

{

a=rs.getInt(1);

}

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

return a;

}

public String availablemnt(String accntid) {

// TODO Auto-generated method stub

String avail=null;

try {

st=con.createStatement();

String availableamnt1="select AMOUNT_DEPOSITED

from account where acc_id='"+accntid+"'";

rs=st.executeQuery(availableamnt1);

while(rs.next())

{

avail=rs.getString(1);

}

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

return avail;

}

public ArrayList getUsermodifydetails(String u) {

// TODO Auto-generated method stub

int nid=0;

Page 66: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

66

String cityid=null;

int sid=0;

int cid=0;

String nname=null;

String cityname=null;

String statename=null;

String name=null;

String gender=null;

int mn=0;

String emailid=null;

String address=null;

String DOB=null;

String cname=null;

ArrayList countryname1=new ArrayList();

Blob blob = null;

try {

st=con.createStatement();

String Userdetails="select

OWNER_NAME,GENDER,MOBILE_NUMBER,EMAIL_ID,ADDRESS,DATE_OF_BIRTH,I

MAGE from userinfo where user_id='"+u+"'";

rs=st.executeQuery(Userdetails);

while(rs.next())

{

name=rs.getString(1);

gender=rs.getString(2);

mn=rs.getInt(3);

emailid=rs.getString(4);

address=rs.getString(5);

DOB=rs.getString(6);

blob=rs.getBlob(7);

}

//

String details="select city_id,n_id from userinfo

where user_id='"+u+"'";

System.out.println(details);

rs=st.executeQuery(details);

while(rs.next())

{

cityid=rs.getString(1);

nid=rs.getInt(2);

}

String state="select s_id,name from city where

city_id='"+cityid+"'";

System.out.println(state);

rs=st.executeQuery(state);

Page 67: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

67

while(rs.next())

{

sid=rs.getInt(1);

cityname=rs.getString(2);

}

String country="select c_id,name from state where

s_id='"+sid+"'";

System.out.println(country);

rs=st.executeQuery(country);

while(rs.next())

{

cid=rs.getInt(1);

statename=rs.getString(2);

System.out.println(statename);

}

String countryname="select name from country

where c_id='"+cid+"'";

rs=st.executeQuery(countryname);

while(rs.next())

{

cname=rs.getString(1);

}

String Nationality="select nationality from

nationality where n_id='"+nid+"'";

System.out.println(Nationality);

rs=st.executeQuery(Nationality);

while(rs.next())

{

nname=rs.getString(1);

System.out.println("the nat is"+nname);

}

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

countryname1.add(name);

countryname1.add(gender);

countryname1.add(mn);

countryname1.add(emailid);

countryname1.add(address);

countryname1.add(DOB);

countryname1.add(cname);

countryname1.add(statename);

countryname1.add(cityname);

countryname1.add(nname);

Page 68: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

68

countryname1.add(blob);

System.out.println("The user info vlues are"

+countryname1);

return countryname1;

}

public int deleteuser(String userID) {

// TODO Auto-generated method stub

int i=0;

try {

st=con.createStatement();

String delete="delete from userinfo where

user_id='"+userID+"'";

st.executeUpdate(delete);

String delete2="delete from vehicle where

user_id='"+userID+"'";

st.executeUpdate(delete2);

String delete3="delete from account where

user_id='"+userID+"'";

i=st.executeUpdate(delete3);

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

return i;

}

public int modifyuserdetails(int uid, String name, String

gender, int mn,

String dob, String email, String address, String

cityname,String nname) {

// TODO Auto-generated method stub

String city=null;

int natio=0;

int i=0;

try {

st=con.createStatement();

String cityid="select city_id from city where

name='"+cityname+"'";

rs=st.executeQuery(cityid);

while(rs.next())

{

city=rs.getString(1);

System.out.println(":::::::::::" +city);

}

Page 69: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

69

String nid="select n_id from nationality where

nationality='"+nname+"'";

System.out.println("::::::::::::::::::::::::::::::::::::

is"+nid);

rs=st.executeQuery(nid);

while(rs.next())

{

natio=rs.getInt(1);

System.out.println(":::::::::::" +natio);

}

String userdetails="update USERINFO set

OWNER_NAME='"+name+"',GENDER='"+gender+"',DATE_OF_BIRTH='"+dob+"

',MOBILE_NUMBER='"+mn+"',EMAIL_ID='"+email+"',ADDRESS='"+address

+"',CITY_ID='"+city+"',N_ID='"+natio+"' where

user_id='"+uid+"'";

i=st.executeUpdate(userdetails);

} catch (SQLException e) {

// TODO Auto-generated catch block

e.printStackTrace();

}

return i;

}

}

Page 70: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

70

CHAPTER-6

TESTING

6.1 Introduction :

Software testing is a critical element of software quality assurance and represents the

ultimate review of specification, design and code generation.

Testing Objectives

To ensure that during operation the system will perform as per specification

To make sure that system meets the user requirements during operation

To make sure that during the operation, incorrect input, processing and output

will be detected

To see that when correct inputs are fed to the system the outputs are correct

To verify that the controls incorporated in the same system as intended

Testing is a process of executing a program with the intent of finding an error

A good test case is one that has a high probability of finding as yet undiscovered

error.

The software developed has been tested successfully using the following testing all that

strategies and any errors that are encountered are corrected and again with the part of the

program or the procedure or function is put to testing until all the errors are removed. A

successful test is one that uncovers an as yet undiscovered error.

Note that the result of the system testing will prove that the system is working correctly.

It will give confidence to system designer, users of the system, prevent frustration during

implementation process etc.

6.2 Design of test cases and scenarios and validation :

6.2.1 White box testing

White box testing is a testing case design method that uses the control structure of the

procedure design to derive test cases. All independents path in a module are exercised at least

once, all logical decisions are exercised at once, execute all loops at boundaries and within their

Page 71: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

71

operational bounds exercise internal data structure to ensure their validity. Here the customer is

given three chances to enter a valid choice out of the given menu. After which the control exits

the current menu.

6.2.2 Black Box Testing

Black Box Testing attempts to find errors in following areas or categories, incorrect or

missing functions, interface error, errors in data structures, performance error and initialization

and termination error. Here all the input data must match the data type to become a valid

entry.The following are the different tests at various levels:

6.2.3 Unit Testing:

Unit testing is essentially for the verification of the code produced during the part

with coding phase and the goal is test the internal logic of the module/program. In the

Generic code project, the unit testing is done during coding phase of data entry forms

whether the functions are working properly or not. In this phase all the drivers are tested

they are rightly connected or not.

6.2.4 Integration Testing:

All the tested modules are combined into sub systems, which are then tested. The

goal is to see if the modules are properly integrated, and the emphasis being on the testing

interfaces between the modules. In the generic code integration testing is done mainly on

table creation module and insertion module.

6.2.5 Validation Testing:

This testing concentrates on confirming that the software is error-free in all respects. All

the specified validations are verified and the software is subjected to hard-core testing. It also

aims at determining the degree of deviation that exists in the software designed from the

specification; they are listed out and are corrected.

6.2.6 System Testing:

This testing is a series of different tests whose primary is to fully exercise the computer-

based system. This involves:

Page 72: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

72

Implementing the system in a simulated production environment and testing it.

Introducing errors and testing for error handling.

6.3 Conclusion :

Note that the result of the system testing will prove that the system is working

correctly. It will give confidence to system designer, users of the system, prevent frustration

during implementation process etc.

Page 73: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

73

6.2 Test cases:

Test case for verifying Authentication

Table 6.1: Test case for Verifying Authentication

Test case 1: Verifying Authentication.

Test Objective: For Verifying Authentication.

Test Description: “Admin enters username and password and presses submit button”, client program

contacts with the database, database checks for authentication and sends result as a valid user.

Requirements Verified: Yes

Test Environment: Database Should contain appropriate table and link must be established between

server and client program.

Test Setup/Pre-Conditions: Username and Password fields should be entered.

Actions Expected Results

The Admin will select submit button to access

application.

“Service Found”, “.Displays Home Page”

Pass: Yes Conditions pass: Yes Fail: No

Problems / Issues: NIL

Notes: Successfully Executed

Page 74: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

74

Test Case for Action

Table 6.2: Test case to select type of action

Test case 2: To select type of action in home page.

Test Objective: To select type of action in home page.

Test Description: “Admin selects any one of the registration (user, vehicle, and tollgate)

program checks and should navigate to the respective registration pages.

Requirements Verified: Yes

Test Environment: Navigation should be given correctly to for every button.

Test Setup/Pre-Conditions: Respective button should be clicked.

Actions Expected Results

The Admin will select respective

registration button to access application.

“Service Found”, “.Displays respective pages”

Pass: Yes Conditions pass: Yes Fail: No

Problems / Issues: NIL

Notes: Successfully Executed

Page 75: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

75

Test case for Registration of user

Table 6.3: Test case for Registration of user

Test case 3: Registration of user

Test Objective: Registration of user

Test Description: “Admin fills the registration form of user by entering all the details and after

clicking submits button data should be entered into database table and page should be

navigated to account registration page.

Requirements Verified: Yes

Test Environment: Database should contain respective table with the correct fields

.Navigation should be given correctly to for submit button.

Test Setup/Pre-Conditions: All Fields in the form should be entered.

Actions Expected Results

The Admin will select submit button to

access application.

“Service Found”, “.Displays Account Registration

page”

Pass: Yes Conditions pass: Yes Fail: No

Problems / Issues: NIL

Notes: Successfully Executed

Page 76: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

76

Test case for Account creation

Table 6.4: Test case for Account creation

Test case 4: Creation of account

Test Objective: For Account Creation

Test Description: “Admin fills the form of account and selects account type (post-paid

or prepaid). If it is prepaid, amount should be deposited. And after clicking submits

button data should be entered into database table and page should be navigated to

vehicle registration page.

Requirements Verified: Yes

Test Environment: Database should contain respective table with the correct fields

.Navigation should be given correctly to for submit button.

Test Setup/Pre-Conditions: All Fields in the form should be entered.

Actions Expected Results

The Admin will select submit button

to access application.

“Service Found”, “.Displays Vehicle

Registration page”

Pass: Yes Conditions pass: Yes Fail: No

Problems / Issues: NIL

Notes: Successfully Executed

Page 77: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

77

Test case for Registration of vehicle

Table 6.5: Test case for Registration of vehicle

Test case 5: Registration of vehicle

Test Objective: For Registration of vehicle

Test Description: “Admin reads the tag after creation of account (Tag Id should be

displayed in text field) and enter all the details of vehicle. And after clicking submits

button data should be entered into database table and page should be navigated to

Home page.

Requirements Verified: Yes

Test Environment: Database should contain respective table with the correct fields

.Navigation should be given correctly to for submit button.

Test Setup/Pre-Conditions: All Fields in the form should be entered.

Actions Expected Results

The Admin will select submit button to

access application.

“Service Found”, “.Displays Home page”

Pass: Yes Conditions pass: Yes Fail: No

Problems / Issues: NIL

Notes: Successfully Executed

Page 78: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

78

Test case for Registration of Tollgate

Table 6.6: Test case for Registration of Tollgate

Test case 6: Registration of Tollgate

Test Objective: Registration of Tollgate

Test Description: “Admin fills the registration form of Tollgate by entering all the

details and after clicking submits button data should be entered into database table

and gets alert please enter amount details.

Requirements Verified: Yes

Test Environment: Database should contain respective table with the correct

fields.

Test Setup/Pre-Conditions: All Fields in the form should be entered.

Actions Expected Results

The Admin will select submit button

to access application.

“Service Found”, “.Displays same page with

alert”

Pass: Yes Conditions pass: Yes Fail: No

Problems / Issues: NIL

Notes: Successfully Executed

Page 79: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

79

Test case for inserting amount for each vehicle type

Table 6.7: Test case for inserting amount for each vehicle type

Test case 7: Inserting amount for each vehicle type

Test Objective: For inserting amount for each vehicle type

Test Description: “Admin enters the amount for each vehicle type after registering the

Tollgate. And after clicking submits button data should be entered into database table and

gets alert insertion completed.

Requirements Verified: Yes

Test Environment: Database should contain respective table with the correct fields.

Test Setup/Pre-Conditions: All Fields in the form should be entered.

Actions Expected Results

The Admin will select submit button to

access application.

“Service Found”, “.Displays same page with alert”

Pass: Yes Conditions pass: Yes Fail: No

Problems / Issues: NIL

Notes: Successfully Executed

Page 80: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

80

Test case for Tracking

Table 6.8: Test case for Tracking

Test case 8: For tracking

Test Objective: For tracking

Test Description: Reader at tollgate reads the tag and get the details of the vehicle and also

amount will be deducted (if prepaid) /added (id post paid). Details of tracking should be entered

into database table and SMS alert should be sent to the user mobile.

Requirements Verified: Yes

Test Environment: Database should contain respective table with the correct fields.

Test Setup/Pre-Conditions: Reader reads the tag.

Actions Expected Results

The reader reads the tag and access

application.

“Service Found”, “.Displays same page and reader

tracks another vehicle”

Pass: Yes Conditions pass: Yes Fail: No

Problems / Issues: NIL

Notes: Successfully Executed

Page 81: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

81

Test case for modifying details of user

Table 6.9: Test case for modifying details of user

Test case 9: For modifying details of user

Test Objective: For modifying details of user

Test Description: Admin enters user id and clicks submit button. Page should navigate to

modify page, after clicking edit button it should allow the admin to edit. Then after clicking

submits button details of the user should be updated in the database.

Requirements Verified: Yes

Test Environment: Database should contain respective table with the correct fields.

Navigation should be given correctly to for submit button.

Test Setup/Pre-Conditions: Reader reads the tag.

Actions Expected Results

The Admin will select submit button to

access application.

“Service Found”, “.Displays alert and navigates to

home page”

Pass: Yes Conditions pass: Yes Fail: No

Problems / Issues: NIL

Notes: Successfully Executed

Page 82: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

82

Test case for deleting details of user

Table 6.10: Test case for deleting details of user

Test case 10: For deleting details of user

Test Objective: For deleting details of user

Test Description: Admin enters user id and clicks submit button then respective details of user

should be deleted along with account and vehicle details.

Requirements Verified: Yes

Test Environment: Database should contain respective table with the correct fields.

Navigation should be given correctly to for submit button.

Test Setup/Pre-Conditions: User ID should be entered.

Actions Expected Results

The Admin will select submit button to

access application.

“Service Found”, “.Displays alert and navigates to

home page”

Pass: Yes Conditions pass: Yes Fail: No

Problems / Issues: NIL

Notes: Successfully Executed

Page 83: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

83

Test case for Complaint

Table 6.11: Test case for Complaint

Test case 11: For complaint

Test Objective: For complaint

Test Description: Admin fills the complaint form by entering all the details given by user

and after clicking submits button data should be entered into database table and page

should be navigated to home page after getting alert.

Requirements Verified: Yes

Test Environment: Database should contain respective table with the correct fields.

Navigation should be given correctly to for submit button.

Test Setup/Pre-Conditions: All fields in the form should be entered.

Actions Expected Results

The Admin will select submit button to

access application.

“Service Found”, “.Displays alert and navigates

to home page”

Pass: Yes Conditions pass: Yes Fail: No

Problems / Issues: NIL

Notes: Successfully Executed

Page 84: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

84

Test case for tracking complaint registered vehicle

Table 6.12: Test case for tracking complaint registered vehicle

Test case 12: Tracking complaint registered vehicle

Test Objective: Tracking complaint registered vehicle

Test Description: Reader reads the tag affixed to the vehicle. If the tag is registered with the

complaint then alter should be raised.

Requirements Verified: Yes

Test Environment: Database should contain respective table with the correct fields.

Test Setup/Pre-Conditions: Reader reads the tag.

Actions Expected Results

The reader reads the tag and access

application.

“Service Found”, “. Displays same page and

reader tracks another vehicle”

Pass: Yes Conditions pass: Yes Fail: No

Problems / Issues: NIL

Notes: Successfully Executed

Page 85: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

85

Test case for Recharge

Table 6.13: Test case for Recharge

Test case 13: For recharge

Test Objective: For recharge

Test Description: Admin fills the recharge form by entering all the details given by user and

after clicking submits button data should be entered into database table and page should be

navigated to home page after getting alert. SMS alert should be sent to the user.

Requirements Verified: Yes

Test Environment: Database should contain respective table with the correct fields.

Navigation should be given correctly to for submit button.

Test Setup/Pre-Conditions: All fields in the form should be entered.

Actions Expected Results

The Admin will select submit button to

access application.

“Service Found”, “.Displays alert and navigates to

home page”

Pass: Yes Conditions pass: Yes Fail: No

Problems / Issues: NIL

Notes: Successfully Executed

Page 86: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

86

CHAPTER-7

RESULTS

7.1 Admin Login :

Fig 7.1 HomeScene

The admin login page is for the administrator to enter their username and password to access the

main page.

Page 87: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

87

7.2 Registration:

Fig 7.2 Registration

The registration page has three options one for new users to register which includes entering the

owners details the vehicle details and account registration.

Next option is for already registered users, which has options for registering for another vehicle,

lodge a complaint or recharge his account.

The tollgates also need to register likewise.

Page 88: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

88

7.3 Owner Details:

Fig 7.3 User Registration

The owner needs to enter all the details in this form, so that the information can be stored in the

database for further use.

Page 89: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

89

7.3.1 Account Registration:

Fig7.3.1 Account Registration

The owners account details that include entering a three digit account id that is unique to each

owner, the initial amount also needs to be entered to be deposited into the account ,it could be

either prepaid or postpaid.

The amount deposited textbox will not be available if the postpaid account type is selected.

Page 90: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

90

7.3.2 Vehicle Information:

Fig7.3.2 Vehicle Information

In this page, the owner’s vehicle information, including the twelve digit RFID tag ID needs to be

give, to register the tag to the vehicle.

Page 91: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

91

7.4 Registered Vehicle:

Fig 7.4 Registered Vehicle

The owners who have already registered, can register for another vehicle of their own, recharge

their account or if the registered vehicle is lost, a complaint can be lodged for its recovery.

Page 92: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

92

7.4.1 ACCOUNT RECHARGE:

Fig 7.4.1 Account Recharge

The owners account balance should be recharged when the balance is low. The account id that is

given to the owner during registration needs to be entered and the amount for recharge is to be

entered.

Page 93: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

93

7.4.2 Complaint:

Fig 7.4.2 Vehicle Lost Complaint

The owners can book a complaint on this page when a vehicle with a registered RFID tag is lost,

the vehicle which has a complaint booked, when detected at a tollgate the system will generate

an alert and it can be ceased.

Page 94: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

94

7.5 Tollgate Registration:

Fig 7.5 Tollgate Registration

Tollgate managements need to register in this page and provide details about their location, the

toll amount for each vehicle type that passes the tollgate. Each one registered will have a unique

ID.

Page 95: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

95

7.6 No Parking Zone:

Fig 7.6 No Parking Zone

No parking zones can be monitored constantly without human involvement in this module. The

vehicle when parked at such a place will be given a fine that is deducted from the owners

account balance.

Page 96: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

96

7.7 Tracking

Fig 7.7 Tracking

The tag registered vehicle when approaches a tollgate, the reader detects the tag and the toll

amount deduction is done automatically. the vehicle need not even stop at the tollgate.

Page 97: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

97

7.7.1 Stolen Vehicle Tracking:

Fig 7.7.1 Stolen Vehicle Tracking

As a vehicle which has a complaint booked on it, approaches the tollgate the system will give an

alert and the officials can cease it and help in the recovery of the vehicle to the owner.

Page 98: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

98

CHAPTER-8

CONCLUSION

In the current times of increasing traffic on the road, it is important to collect the toll tax in a

managed and controlled process so that it doesn't result in a total unorganized jungle of traffic. It

is very challenging to handle a vehicular flow by a manual system of revenue collection. Poor

management at toll plaza may result into great chaos and revenue loss. Using RFID technology

at tollgates makes transactions very easy, as the vehicle need not stop and pay the tax by hand,

thus making it very convenient for the public.

Page 99: TollGate SystemMobile Showroom Billing and Inventory Management is developed for established mobile showroom in the city. To manage all operations of the show room this project is

99

CHAPTER-9

BIBLIOGRAPHY

Grady Booch, James Rumbaugh, Ivar Jacobson, “THE UNIFIED

MODELING LANGUAGE User Guide”.

Roger S. Pressman, “SOFTWARE ENGINEERING”.

Herbert Schildt, “JAVA: THE COMPLETE REFERENCE-7th

EDITION”.

Ragu Ramakrishnan and Johannes Gehrke ,“DATABASE MANAGEMENT

SYSTEMS”.

Boris Beizer, “SOFTWARE TESTING TECHNIQUES-SECOND

EDITION”

http://delonti.com/whatisRFID.aspx

http://delonti.com/PublicVehicleTrack.aspx

http://www.technovelgy.com/ct/technology-article.asp

http://electronics.howstuffworks.com/gadgets/high-techgadgets/rfid.htm

http://www.webopedia.com/TERM/R/RFID.html