namsu55
asked on
How to display an SQL query into a JTable in Netbeans
I currently have a TableModel bound to a table in the database, the values and columns output fine. However, is there any possible way to make an sql query rather than display one table. I have made an SQL View from Netbeans under Services/Databases for the database, but can't seem to use it anywhere for the table model.
You can make the query using a SwingWorker (see excellent docs) and then set a new DefaultTableModel
ASKER
But would I be able to use foreign keys. Two joined tables in one table model through netbeans.
ASKER
How do I manipulate the Table Model in Netbeans for a JTable.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thanks CEHJ just having a go at it.