Midterm Project
dbBrowser
Sanjay Sthapit
dbBrowser is a simple java application
for intuitive browsing of databases. It utilizes the new swing package
- particulary the JTable class - and the jdbc drivers to provide
an interface to the database. To browse a database, the user first must
enter information in the following window :-
The user must specify a username, a password, a URL
for the database, and is allowed to specify the driver that facilitates
the connection to the database. A connection is then established and the
following main window provides theinterface to the database :-
The user is able to select any of the tables in the
database by selecting it in the list box marked table. This automatically
generates an editable listbox for each column with all values of the column
listed as values in the listbox. There is also a checkbox beside each listbox.
The user can now construct simple queries with this graphical interface,
run them on the database, and have the results be automatically displayed
in the table.
Select: checked listboxes identify columns
to be displayed and filled listboxes specify filters to the query ("any/all"
signifying the wildcard character).
Insert: a new row is inserted with the values
filled in the listboxes.
Delete: rows are deleted with values filled
in listboxes as filters.
Clear: clears all choices and displays the
entire table.
The JTable allows some nice features in the table
such as sorting rows by the column double clicked on, and the ability to
rearrange columns.
SOURCE CODE