Entry
display data from DataBase in JTable using JDBC
Sep 4th, 2007 03:26
Jemmy wilson, Triveni ds, http://www.itindiasolutions.com
The java.sql package defines the JDBC API for sending SQL queries and
update statements to a database, and for obtaining query results. This
article uses examples that did not fit in the second edition of my
book, Java Examples in a Nutshell, to demonstrate how to use JDBC to
connect to a database and obtain a java.sql.Connection object, how to
execute a SQL query using a java.sql.Statement object, and how to work
with the query results returned in a java.sql.ResultSet object.
The javax.swing package contains the Swing graphical user interface
components. One of the most powerful of these components is JTable,
which as its name suggests, displays tables. JTable can display any
type of tabular data as long as it implements the
javax.swing.table.TableModel interface. The examples in this article
include a TableModel implementation that interprets a JDBC ResultSet
object, so that the queried data can be displayed by a JTable,
For more Detail :
http://www.oreillynet.com/pub/a/oreilly/java/news/javaex_1000.html