Results 1 to 2 of 2
  1. #1
    asifzbaig is offline Member
    Join Date
    May 2011
    Rep Power

    Default Adding and Deleting rows in jTable dynamically?

    Please suggest me how to synchronize a table in GUI with a table in MySQL database......

    Particularly i need to refresh my table automatically as i changed the rows or entity in MySQL table....

    Or more simply talking, i need to add rows in my jTable as per change in MySql table....

    Please help me....

  2. #2
    camickr is offline Senior Member
    Join Date
    Jul 2009
    Rep Power


    The DefaultTableModel has addRow(...) and removeRow(...) methods. So you need to update the model at the same time as you update the database.

Similar Threads

  1. adding dynamic rows to jtable
    By paul4everyone in forum Advanced Java
    Replies: 5
    Last Post: 05-08-2011, 06:37 AM
  2. Adding Rows to a JTable
    By mlad in forum AWT / Swing
    Replies: 3
    Last Post: 05-04-2011, 03:09 AM
  3. JTable insertRows() just adding blank rows
    By Jacob_ in forum AWT / Swing
    Replies: 4
    Last Post: 10-10-2009, 04:56 AM
  4. Deleting rows from a database using JSP
    By Manas Das in forum JavaServer Pages (JSP) and JSTL
    Replies: 2
    Last Post: 02-17-2009, 03:31 PM
  5. Deleting All rows in the JTable
    By surot in forum New To Java
    Replies: 1
    Last Post: 04-16-2008, 11:44 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts