You are on page 1of 48

BOOK STORE MANAGEMENT

A SUMMER TRAINING PROJECT REPORT


Submitted by :

PRATEEK BANSAL

in partial fulfillment for the award of the degree of

BACHELOR OF TECHNOLOGY IN COMPUTER SCIENCE

AUGUST 2011

MAHARAJA AGARSEN INSTITUTE OF TECHNOLOGY, ROHINI, SECTOR-22


Affilaited to GURU GOBIND SINGH INDRAPRASTHA UNIVERSITY, DELHI

COVER LETTER

Center Head, DEVELOPERS, Shalimar Bagh, Delhi-110088 Sir/Madam, We, Prateek Bansal and Vishal Sachdeva are submitting our Core JAVA Project for evaluation, which we made under the guidance of Mr. Rakesh Sharma. Details of the project and my Registration and postal address, etc. are as under: Name Address : : Prateek Bansal and Vishal Sachdeva

AL-148 Shalimar Bagh Delhi-110088

Contact No

9999809562, 9811399070

CERTIFICATE

This is to certify that the Project entitled Book Store Management System is a bonafide work done by Prateek Bansal in partial fulfillment of Core JAVA examination and has been carried out under my direct supervision and guidance. This report or a similar report on the topic has not been submitted for any other examination and does not form part of any other course undergone by the candidate.

Signature of Guide

Date:

ACKNOWLEDGEMENT
I place on record my deep appreciation and gratitude for the help and co-operation rendered to me by numerous members of faculty; Libraries Developers Institute, Delhi; Central Library, Delhi and numerous friends for placing at my disposal various magazines for the collection of statistical data and other relevant information and for rendering every possible assistance in completing my Project Report. But for their unstinted cooperation and support, it would have never been possible for me to undertake this task of exploring and analyzing the commercial ads in magazines and accomplishing the Project successfully. I also owe my gratefulness thanks to Mr. Rakesh Sharma, faculty member of Developers Institute, who helped me in various ways to make this study success. The conclusion arrived at in this project are entirely my own.

Prateek Bansal B.Tech ( CSE) :5th Semester Email: prateekbansal21@hotmail.com

INDEX

DESCRIPTION

PAGE NO.
8

ABSTRACT

INTODUCTION TO BOOK STORE

INTRODUCTION TO JAVA

12

ARCHITECTURE

22

DATA FLOW DIAGRAM ( DFD )

26

STEPS TO IMPLEMENT

30

SNAPSHOTS

32

38 TABLE STRUCTURE

39 CODING

47 CONCLUSION

48 REFERENCE & BIBLIOGRAPHY

TABLE OF CONTENTS

1) 2) 3) 4) 5) 6) 7) 8) 9) 10) 11) 12) 13)

ABSTRACT INTRODUCTION TO BOOK STORE INTRODUCTION TO JAVA ARCHITECTURE DATA FLOW DIAGRAMS ZERO LEVEL DFD INFORMATION FLOW TESTING STEPS TO IMPLEMENT SCREENSHOTS TABLE STRUCTURE CODING CONCLUSION REFERENCES & BIBLIOGRAPHY

ABSTRACT

Purpose of this project is to create a software to manage Book Store using java programming. This software provides basic features like searching books, make new members, maintains the details of book etc. It also provides functionality to choose or search for different types of books in the Big Book store to customers. This will help a Book Store to manage their work very well.

This document is provided as an online-only resource so that it may be continually extended and updated. This document begins with a description of separate applications and provides in depth description of several pieces of modules.

INTRODUCTION OF BOOK STORE WORLD

Purpose of this project is to create a software to manage Book Store using java programming. This software provides basic features like searching books, make new members, maintains the details of book etc. It also provides functionality to choose or search for different types of books in the Big book store to customers. This will help a Book Store to manage their work very well.

This document is provided as an online-only resource so that it may be continually extended and updated. This document begins with a description of separate applications and provides in depth description of several pieces of modules.

1) Each Book store world module has different requirements from


others. This section describes the requirements, design and implementation of each module.
9

2) Administrator module: Initially administrators have to login his/her module by using the username and the password.

3) Members module: If anyone is a member of the book store then he/she can get a new login id and password so that he/she can access the searching option in which members get special discounts(say 10%).

4) Customers module:
This module is basic module just provide the searching option so that the customer got the details of the book i.e. name of the book, price of the book and location of the book.

10

EXTERNAL INTERFACE REQUIREMENTS


HARDWARE INTERFACES

Screen resolution of at least 800*600 or above will be preferable for viewing the multimedia presentations.
SOFTWARE INTERFACES It should be possible for Book Store Management to be implemented in both Windows and Linux Operating System environments. The GUI and other parts of the Book Store Management software are to be done in JAVA. The output of this software will need a web browser for viewing it.

11

INTRODUCTION TO JAVA

Java was developed at Sun Microsystems. Work on Java initially began with the goal of creating a platform-independent language and OS for consumer electronics. The original intent was to use C++, but as work progressed in this direction, developers identified that creating their own language would serve them better. The effort towards consumer electronics led the Java team, then known as First Person Inc., towards developing h/w and s/w for the delivery of video-on-demand with Time Warner.

12

Today Java is both a programming language and an environment for executing programs written in Java Language. Unlike traditional compilers, which convert source code into machine level instructions, the Java compiler translates java source code into instructions that are interpreted by the runtime Java Virtual Machine. So unlike languages like C and C++, on which Java is based, Java is an interpreted language. Java is the first programming language designed from ground up with network programming in mind. The core API for Java includes classes and interfaces that provide uniform access to a diverse set of network protocols. As the Internet and network programming have evolved, Java has maintained its cadence. New APIs and toolkits have expanded the available options for the Java network programmer. FEATURES OF JAVA

In one of their early papers about the language, Sun described Java as follows: Java: A simple, object-oriented, distributed, interpreted, robust, secure, architecture neutral, portable, high-performance, multithreaded, and dynamic language. Sun acknowledges that this is quite a string of buzzwords, but the fact is that, for the
13

most part, they aptly describe the language. In order to understand why Java is so interesting, let's take a look at the language features behind the buzzwords.
OBJECT-ORIENTED

Java is an object-oriented programming language. As a programmer, this means that you focus on the data in your application and methods that manipulate that data, rather than thinking strictly in terms of procedures. If you're accustomed to procedure-based programming in C, you may find that you need to change how you design your programs when you use Java. Once you see how powerful this new paradigm is, however, you'll quickly adjust to it. In an object-oriented system, a class is a collection of data and methods that operate on that data. Taken together, the data and methods describe the state and behavior of an object. Classes are arranged in a hierarchy, so that a subclass can inherit behavior from its super class. A class hierarchy always has a root class; this is a class with very general behavior. Java comes with an extensive set of classes, arranged in packages that you can use in your programs. For example, Java provides classes that create graphical user interface components (the java.awt package), classes that handle input and output (the java.io package), and classes that support networking functionality (the java.net package). The Object class (in the java.lang package) serves as the root of the Java class hierarchy. Unlike C++, Java was designed to be object-oriented from the ground up. For a complete description of the objectoriented features of Java, the object oriented language used to create executable contents such as applications and applets. INTERPRETED Java is an interpreted language: the Java compiler generates byte-codes for the Java Virtual Machine (JVM), rather than native machine code. To actually run a Java program, you use the Java interpreter to execute the compiled byte-codes. Because Java byte-codes are platform-independent, Java programs can run on any platform that the JVM (the interpreter and run-time system) has been ported to. In an interpreted environment, the standard "link" phase of program development
14

pretty much vanishes. If Java has a link phase at all, it is only the process of loading new classes into the environment, which is an incremental, lightweight process that occurs at run-time. This is in contrast with the slower and more cumbersome compile-link-run cycle of languages like C and C++. ARCHITECTURE NEUTRAL AND PORTABLE Because Java programs are compiled to an architecture neutral byte-code format, a Java application can run on any system, as long as that system implements the Java Virtual Machine. This is a particularly important for applications distributed over the Internet or other heterogeneous networks. But the architecture neutral approach is useful beyond the scope of network-based applications. As an application developer in today's software market, you probably want to develop versions of your application that can run on PCs, Macs, and UNIX workstations. With multiple flavors of UNIX, Windows 95, and Windows NT on the PC, and the new PowerPC Macintosh, it is becoming increasingly difficult to produce software for all of the possible platforms. If you write your application in Java, however, it can run on all platforms. The fact that Java is interpreted and defines a standard, architecture neutral, byte-code format is one big part of being portable. But Java goes even further, by making sure that there are no "implementation-dependent" aspects of the language specification. For example, Java explicitly specifies the size of each of the primitive data types, as well as its arithmetic behavior. This differs from C, for example, in which an int type can be 16, 32, or 64 bits long depending on the platform. DYNAMIC AND DISTRIBUTED Java is a dynamic language. Any Java class can be loaded into a running Java interpreter at any time. These dynamically loaded classes can then be dynamically instantiated. Native code libraries can also be dynamically loaded. Classes in Java are represented by the Class class; you can dynamically obtain information about a class at run-time. This is especially true in Java 1.1, with the addition of the
15

Reflection API. Java is also called a distributed language. This means, simply, that it provides a lot of high-level support for networking. For example, the URL class and Oar elated classes in the java.net package make it almost as easy to read a remote file or resource as it is to read a local file. Similarly, in Java 1.1, the Remote Method Invocation (RMI) API allows a Java program to invoke methods of remote Java objects, as if they were local objects. (Java also provides traditional lower-level networking support, including datagram's and stream-based connections through sockets.) The distributed nature of Java really shines when combined with its dynamic class loading capabilities. Together, these features make it possible for a Java interpreter to download and run code from across the Internet. SIMPLE Java is a simple language. The Java designers were trying to create a language that a programmer could learn quickly, so the number of language constructs has been kept relatively small. Another design goal was to make the language look familiar to a majority of programmers, for ease of migration. If you are a C or C++ programmer, you'll find that Java uses many of the same language constructs as C and C++. In order to keep the language both small and familiar, the Java designers removed a number of features available in C and C++. These features are mostly ones that led to poor programming practices or were rarely used. For example, Java does not support the goto statement; instead, it provides labeled break and continue statements and exception handling. Java does not use header files and it eliminates the C preprocessor. Because Java is object-oriented, C constructs like struct and union have been removed. Java also eliminates the operator overloading and multiple inheritance features of C++. Perhaps the most important simplification, however, is that Java does not use pointers. Pointers are one of the most bug-prone aspects of C and C++ programming. Since Java does not have structures, and arrays and strings are objects, there's no need for pointers. Java automatically handles the referencing and dereferencing of objects for you. Java also implements

16

automatic garbage collection, so you don't have to worry about memory management issues. ROBUST Java has been designed for writing highly reliable or robust software. Java certainly doesn't eliminate the need for software quality assurance; it's still quite possible to write buggy software in Java. However, Java does eliminate certain types of programming errors, which makes it considerably easier to write reliable software. Java is a strongly typed language, which allows for extensive compiletime checking for potential type-mismatch problems. Java is more strongly typed than C++, which inherits a number of compile-time laxities from C, especially in the area of function declarations. Java requires explicit method declarations; it does not support C-style implicit declarations. These stringent requirements ensure that the compiler can catch method invocation errors, which leads to more reliable programs. One of the things that makes Java simple is its lack of pointers and pointer arithmetic. This feature also increases the robustness of Java programs by abolishing an entire class of pointer-related bugs. Similarly, all accesses to arrays and strings are checked at run-time to ensure that they are in bounds, eliminating the possibility of overwriting memory and corrupting data. Casts of objects from one type to another are also checked at run-time to ensure that they are legal. Finally, and very importantly, Java's automatic garbage collection prevents memory leaks and other pernicious bugs related to memory allocation and deallocation. Exception handling is another feature in Java that makes for more robust programs. An exception is a signal that some sort of exceptional condition, such as a "file not found" error, has occurred. Using the try/catch/finally statement, you can group all of your error handling code in one place, which greatly simplifies the task of error handling and recovery. SECURE One of the most highly touted aspects of Java is that it's a secure language. This is especially important because of the distributed nature of Java. Without an
17

assurance of security, you certainly wouldn't want to download code from a random site on the Internet and let it run on your computer. Yet this is exactly what people do with Java applets every day. Java was designed with security in mind, and provides several layers of security controls that protect against malicious code, and allow users to comfortably run untrusted programs such as applets. At the lowest level, security goes hand-in-hand with robustness. As we've already seen, Java programs cannot forge pointers to memory, or overflow arrays, or read memory outside of the bounds of an array or string. By totally disallowing any direct access to memory, an entire huge, messy class of security attacks is ruled out. The second line of defense against malicious code is the byte-code verification process that the Java interpreter performs on any untrusted code it loads. These verification steps ensure that the code is well-formed--that it doesn't overflow or underflow the stack or contain illegal byte-codes, for example. If the byte-code verification step was skipped, inadvertently corrupted or maliciously crafted bytecodes might be able to take advantage of implementation weaknesses in a Java interpreter. Another layer of security protection is commonly referred to as the "sandbox model": untrusted code is placed in a "sandbox," where it can play safely, without doing any damage to the "real world," or full Java environment. When an applet, or other untrusted code, is running in the sandbox, there are a number of restrictions on what it can do. The most obvious of these restrictions is that it has no access whatsoever to the local file system. There are a number of other restrictions in the sandbox as well. These restrictions are enforced by a Security Manager class. The model works because the entire core Java classes that perform sensitive operations, such as file system access, first ask permission of the currently installed Security Manager. If the call is being made, directly or indirectly, by untrusted code, the security manager throws an exception, and the operation is not permitted. Finally, in Java 1.1, there is another possible solution to the problem of security. By attaching a digital signature to Java code, the origin of that code can be established in a cryptographically secure and unforgettable way

18

MULTITHREADED In a GUI-based network application such as a Web browser, it's easy to imagine multiple things going on at the same time. A user could be listening to an audio clip while she is scrolling a page, and in the background the browser is downloading an image. Java is a multithreaded language; it provides support for multiple threads of execution (sometimes called lightweight processes) that can handle different tasks. An important benefit of multithreading is that it improves the interactive performance of graphical applications for the user. If you have tried working with threads in C or C++, you know that it can be quite difficult. Java makes programming with threads much easier, by providing built-in language support for threads. The java.lang package provides a Thread class that supports methods to start and stop threads and set thread priorities, among other things. The Java language syntax also supports threads directly with the synchronized keyword. This keyword makes it extremely easy to mark sections of code or entire methods that should only be run by a single thread at a time. While threads are "wizard-level" stuff in C and C++, their use is commonplace in Java. Because Java makes threads so easy to use, the Java class libraries require their use in a number of places. For example, any applet that performs animation does so with a thread. Similarly, Java does not support asynchronous, non-blocking I/O with notification through signals or interrupts--you must instead create a thread that blocks on every I/O channel you are interested in. Java Runtime Environment The runtime environment used to execute the code. It is made up of the java language and java virtual machine. It is portable and it is platform neutral. Java tools It is used by the developers to create java code. They include java compiler, java interpreter, classes, libraries and applet viewer. Java Application Applications are programs written in java to carry out certain tasks on stand alone local computer. Execution of a stand alone program involves two steps. Compiling the source code into byte code using javac. Executing byte code program using java interpreter.
19

Java Applets Java applets are pieces of java code that are embedded in HTML document using the applet tag. When the browser encounters such code it automatically download it and execute it. Java Virtual Machine It is a specification to which java codes must be written. All java code is to be compiled to be used in this nonexistent virtual machine. Writing the code which compiles in JVM ensures platform independence.

INTRODUCTION & PURPOSE

A Book Store Management system (BSMS) is a software application for education establishments to manage student data. Book Store Management systems provide capabilities for entering student data and other details through an electronic grade book, building student records, tracking student details, and managing many other student-related data needs in a Book Management. Also known as student book information management system (SBIMS), book records system (BRS).

These systems vary in size, scope and capability, from packages that are
implemented in relatively small organizations to cover students book records alone, to enterprise-wide solutions that aim to cover most aspects of running large multi-campus organizations with significant local responsibility. Many systems can be scaled to different levels of functionality by purchasing addon "modules" and can typically be configured by their home institutions to meet local needs.

SCOPE
The scope of the project is the system on which the software is installed, i.e. the project is developed as a desktop application, and it will work for a particular institute. But later on the project can be modified to operate it online

20

FEATURES
Until recently, the common functions of a book records system are to support the maintenance of personal and study information relating to: Handling records of prospective students Handling the issuing process Enrolling new students and storing data/details option choices Automatically creating groups of books according to the author. Handling records of students /members. Recording details students Maintaining fine records

Providing statistical report

21

ARCHITECTURE

A Book Store management is a software which is used to manage the book store.

In this software there are three modules: 1) Administrator 2) Members 3) Customers

ADMINISTRATOR MODULE: Initially administrators have to login his/her module by using the username and the password.

Administrator has a number of options: 1. He/she can insert new book details. 2. He/she can remove or delete any book record.

22

3. He/she can add new members.

INSERT OPTION: The administrator just have to insert the datails of the book i. e name of the book , price of the book and location of the book. The imformation directly go to the database which can be used for other purposes.

DELETE OPTION: The administrator have to only write the name of the book ,the required book is deleted from the database of the book store.

NEW MEMBER OPTION: In this option administrator can add new members by adding the details of new member . There are four basic details of the member which is stored in the database i.e name of the customer , address of the customer , telephone number and e-mail ID.
23

MEMBERS MODULE: If any one is a member of the book store then he/she can get a new login id and password so that he/she can access the searching option in which members get special discounts(say 10%).

SEARCHING OPTION: In this option there are two stages for members.firstly he/she have to choose the type of the book(such as mythology , fantasy , fiction etc.), the he/she have to just write the book name which results in displaying the details of the book i.e name of the book , price of the book and location of the book. Price for members are lesser than the non-member customer. CUSTOMERS MODULE: This module is basic module just provide the searching option so that the customer got the details of the book i.e name of the book , price of the book and location of the book.
24

SEARCHING OPTION: In this option there are two stages for customers. firstly he/she have to choose the type of the book(such as mythology , fantasy , fiction etc.), the he/she have to just write the book name which results in displaying the details of the book i.e name of the book , price of the book and location of the book.

25

DATA FLOW DIAGRAMS

DFDs are graphical description showing flow of data between various processes of the system. It helps user to visualize how a system will operate, what it will accomplish.

The main merit of DFD is that it can provide an overview of what data system would process , what transformation of data are done , what files are used and where the result flows. A DFD, also known as data flow graph or a bubble chart, help users to visualize how a system will operate, what it will accomplish and how it shall be implemented. They can also be used to provide the end user with a physical idea of where the data they input ultimately has an effect upon the structure of the whole system from order to dispatch to restock DFDs are structured in such a way hat starting from a simple diagram which provides a broad view at a glance, they can be expanded to a hierarchy of diagrams giving to more and more details.
26

Symbols used in DFDs are as follows: Arrows: Used to connect processes to each other, to sources or sinks, indicating the direction of data flow. Symbol:

Circle: Represents a process that transforms incoming data to yield output data. Symbol:

Rectangle: Represents a source of system inputs or sink of system outputs. Symbol:

27

DATA STORE:
Open ended rectangle / parallel lines data store : They store data for future purposes. Symbol :

INFORMATION FLOW OF DATA TESTING

SOFTWARE CONFIGURATION

TEST CONFIGURATION

EVALUATION

TESTING
ERROR RATE TEST CONFIGURATION DATA

EXPECTED RESULTS

DEBUG

CORRECTION

RELIABILITY MODEL 28

ZERO LEVEL DFD

MEMBERS

ADMINISTRATOR

CUSTOMERS

DELETE INSERT

MEMBER DETAILS ENTRY

SEARCH

SEARCH

BOOK STORE MANAGEMENT

BOOKS DELETED

BOOKS INSERTED

SEARCH RESULT

29

STEPS TO IMPLEMENT

While using the software following steps must be kept in mind and should be implemented.

1) Firstly we need a Net-Beans IDE (integrated development environment). The software is only run on Net-Beans.

Net Beans is a great little tool for those who build web application and for software development. It is an IDE which is avalaible as open source software. Best of all, you can run this program on most of the operating system including windows, linux,mac,Solaris etc.

2) Then open the source package of java application 13(i.e the name of the project in Net-Beans).

30

3) Then for running the software we have run the NewJframe21.java(i.e. the welcome window of the software).

31

SCREEN SHOTS

32

WELCOME SCREEN:

33

OPTION WINDOW:

34

ADDING NEW MEMBER:

35

SEARCHING :

36

SEARCH RESULT:

37

TABLE STUCTURES

DATABASE

38

CODING
39

WELCOME PAGE:
package javaapplication13; public class NewJFrame21 extends javax.swing.JFrame { public NewJFrame21() { initComponents(); } private void jButton1ActionPerformed(java.awt.event.ActionEvent evt) { String s3=evt.getActionCommand(); if(s3.equals("ENTER")) { setVisible(false); NewJFrame5 o=new NewJFrame5 (); o.setVisible(true); } }

public static void main(String args[]) { java.awt.EventQueue.invokeLater(new Runnable() { public void run() { new NewJFrame21().setVisible(true); } }); } private javax.swing.JButton jButton1; private javax.swing.JLabel jLabel1; private javax.swing.JLabel jLabel2; 40

private javax.swing.JLabel jLabel3; private javax.swing.JPanel jPanel1; }

INSERT OPERATION:
public class NewJFrame2 extends javax.swing.JFrame { public NewJFrame2() { initComponents(); } private void jButton2ActionPerformed(java.awt.event.ActionEvent evt) { String s=evt.getActionCommand(); if(s.equals("BACK")) { setVisible(false); NewJFrame1 obj=new NewJFrame1 (); obj.setVisible(true);

} }

// TODO add your handling code here:

private void jButton1ActionPerformed(java.awt.event.ActionEvent evt) { String s3=evt.getActionCommand(); if(s3.equals("ENTER")) { String s1=jTextField1.getText(); String k=jTextField2.getText(); int s2=Integer.valueOf(k); String s4=jTextField1.getText(); Connection con=null; PreparedStatement st = null;

try { Class.forName("sun.jdbc.odbc.JdbcOdbcDriver"); 41

con = DriverManager.getConnection("jdbc:odbc:GEETANJALI"); } catch(Exception e) { System.out.println(e.getMessage()); } Try { st=con.prepareStatement("Insert into BOOKS values(?,?,?)");

st.setString(1,s1); st.setInt(2,s2); st.setString(3,s4); int n= st.executeUpdate(); if(n==1) { NewJFrame1 obj=new NewJFrame1 (); obj.setVisible(true); setVisible(false); st.close(); con.close(); } } catch(Exception e) { System.out.println(e.getMessage()); } } else {System.exit(0); }

// Variables declaration - do not modify 42

private javax.swing.JButton jButton1; private javax.swing.JButton jButton2; private javax.swing.JLabel jLabel1; private javax.swing.JLabel jLabel2; private javax.swing.JLabel jLabel3; private javax.swing.JLabel jLabel4; private javax.swing.JPanel jPanel1; private javax.swing.JTextField jTextField1; private javax.swing.JTextField jTextField2; private javax.swing.JTextField jTextField3;

SEARCH OPERATION:
private void jButton1ActionPerformed(java.awt.event.ActionEvent evt) { String s=evt.getActionCommand(); int n; if(s.equals("ENTER")) { String s1=jTextField1.getText(); Connection con=null; Statement st; ResultSet rs; try { Class.forName("sun.jdbc.odbc.JdbcOdbcDriver"); con = DriverManager.getConnection("jdbc:odbc:GEETANJALI"); } catch(Exception e) { System.out.println(e.getMessage()); } Try { st=con.createStatement(); rs=st.executeQuery("Select * from HISTORICAL where bookname='"+s1+"'");

43

String name1[]=new String[5]; String name2[]=new String[5]; int l[]=new int[1]; int i=0; while(rs.next()) { n=2;

name1[i]=rs.getString(1); l[i]=rs.getInt(2); name2[i]=rs.getString(3); i++; } System.out.println();

setVisible(false); NewJFrame10 obj=new NewJFrame10(); obj.setVal(name1,l,name2); obj.setVisible(true); } catch(Exception e) { System.out.println(e.getMessage()); } } else { System.exit(0); } } private void jButton2ActionPerformed(java.awt.event.ActionEvent evt) { String s=evt.getActionCommand(); if(s.equals("BACK")) { setVisible(false); NewJFrame5 obj=new NewJFrame5(); obj.setVisible(true); 44

// TODO add your handling code here:

} private javax.swing.JButton jButton1; private javax.swing.JButton jButton2; private javax.swing.JLabel jLabel1; private javax.swing.JLabel jLabel2; private javax.swing.JPanel jPanel1; private javax.swing.JTextField jTextField1; }

DELETE OPERATION:
private void jButton1ActionPerformed(java.awt.event.ActionEvent evt) { String s=evt.getActionCommand(); if(s.equals("ENTER")) { String s1=jTextField1.getText(); Connection con=null; Statement st; try { Class.forName("sun.jdbc.odbc.JdbcOdbcDriver"); con = DriverManager.getConnection("jdbc:odbc:GEETANJALI"); } catch(Exception e) { System.out.println(e.getMessage()); } Try { st=con.createStatement(); 45

st.executeUpdate("delete * from BOOKS where bookname='"+s1+"'"); NewJFrame1 obj1=new NewJFrame1 (); obj1.setVisible(true); setVisible(false); } catch(Exception e) { System.out.println(e.getMessage()); } } else { System.exit(0); } } private javax.swing.JButton jButton1; private javax.swing.JButton jButton2; private javax.swing.JLabel jLabel1; private javax.swing.JLabel jLabel3; private javax.swing.JPanel jPanel1; private javax.swing.JTextField jTextField1;

46

CONCLUSION
This project that I undertook was truly a very rewarding experience for me in more than one way. It has given a big thrust to my technical knowledge as prospective Software professional. It has also helped me enhance my skills on the personal front. And I feel extremely satisfied by the fact that I have managed to develop the project of course with equal contribution from my team members. I think I have exploited the opportunity that came my way to the fullest extent by increasing my technical know-how and also gaining the valuable work experience apart from studying the other subjects in our curriculum.

47

REFERENCES & BIBLIOGRAPHY

The various references used for this project are: a) Herbert Schlitz (Java 2- the Complete Reference). b) Internet sites including: 1) www.google.com 2) www.java.sun.com

48

You might also like