users@woodstock.java.net

woodstock table and data on it

From: mohindermoo <mohindermo_at_live.co.uk>
Date: Wed, 17 Sep 2008 22:46:42 -0700 (PDT)

private Table tableMonitor = new Table();
  
    public Table getTableMonitor() {
        return tableMonitor;
    }
  
    public void setTableMonitor(Table t) {
        this.tableMonitor = t;
    }
  
   private TableRowGroup monitorTableRowGroup = new TableRowGroup();
  
    public TableRowGroup getMonitorTableRowGroup() {
        return monitorTableRowGroup;
    }
  
    public void setMonitorTableRowGroup(TableRowGroup trg) {
        this.monitorTableRowGroup = trg;
    }
  
    private CachedRowSetDataProvider monitorDataProvider = new
CachedRowSetDataProvider();
    private CachedRowSetXImpl monitorRowSet;
  
    public CachedRowSetDataProvider getMonitorDataProvider() {
        return monitorDataProvider;
    }
  
    public void setMonitorDataProvider(CachedRowSetDataProvider
monitorDataProvider) {
        this.monitorDataProvider = monitorDataProvider;
    }
  
    public CachedRowSetXImpl getMonitorRowSet() {
        return monitorRowSet;
    }
  
    public void setMonitorRowSet(CachedRowSetXImpl monitorRowSet) {
        this.monitorRowSet = monitorRowSet;
    }
    
    public String butonListing_action(){
        try {
            BigDecimal id=new BigDecimal(3);
                
            monitorRowSet = new CachedRowSetXImpl();
            monitorRowSet.setDataSourceName("java:comp/env/jdbc/dbMarake");
            monitorRowSet.setCommand("SELECT M.MONITORID, M.MONITOR_NAME,
M.MONITOR_AUTHORITY FROM DYS.MONITOR M WHERE M.MONITORID>?");
            monitorRowSet.setObject(1,id);
               monitorRowSet.execute();
            monitorDataProvider.setCachedRowSet(monitorRowSet);
            monitorTableRowGroup.setSourceData(monitorDataProvider);
            
            
        } catch (SQLException ex) {
            Logger.getLogger(Page.class.getName()).log(Level.SEVERE, null,
ex);
        }
        
        return null;
    }
  
    public String butonSave_action() {
        //............???
        return null;
    }



When i clicked butonlisting button program executes and the table fills by
data from database and also I have one more column(static text in it) in my
table than database has columns. User enters data in that extra
column(static text).

When I clicked saveButton i want to have all of data in this table. and than
i am going to use some where else.

What should be the code in butonSave_action to do this?


Your help will be highly appreciated.

-- 
View this message in context: http://www.nabble.com/woodstock-table-and-data-on-it-tp19546355p19546355.html
Sent from the Project Woodstock - Users mailing list archive at Nabble.com.