Thanks, Each row is an Object[] and is part of a linked list maintained by the Result object.
An empty row of the same length should be used for modifications. A similar structure is used in jdbcPreparedStatement for sending parameter values to the engine. The updateXXX() methods should work on this empty row and when updateRow() or insertRow() are called, the data is transmitted to the database similar to PreparedStatement. Other details, such as updating the Result object when updateRow() is called should also be taken care of. The java.sql.ResultSet interface is designed to work on one row at a time. When the three row based methods are called (update / insert /delete) the data is sent. Referring to my previous post on this, the rows for an updateable result set will have additional columns for primary keys which allow the engine to know which row was updated. The engine will perform the various constraint checks on the row before inserting / updating it. Fred ----- Original Message ----- From: "Moray Taylor" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: 15 October 2003 13:13 Subject: Re: [Hsqldb-developers] Updatable resultsets Hi Fred/All, I had a quick look at HSQLDB last night, I had a look at the insertRow stuff, I can see how that could be made to work. When moveToInsertRow is called, a flag would be set in the resultset, so that any updateXXX() call would populate a 'holding area', maybe a vector that is indexed by column number, or a Hashtable with the column name as the key (this could cause a problem if two columns were called the same thing, i.e. SELECT across multiple tables.). When the insertRow() function is called, the 'holding area' data would (somehow) be inserted, this is the bit that I don't really understand how do do, would I use an INSERT as normal, or is there some internal method within HSQLDB. I would then have to add the data to the end of the resultset (a requery would be too inefficient, and unpredictable.) As always, any input is greatly appreciated. Thanks Moray ------------------------------------------------------- This SF.net email is sponsored by: SF.net Giveback Program. SourceForge.net hosts over 70,000 Open Source Projects. See the people who have HELPED US provide better services: Click here: http://sourceforge.net/supporters.php _______________________________________________ hsqldb-developers mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/hsqldb-developers ------------------------------------------------------- This SF.net email is sponsored by: SF.net Giveback Program. SourceForge.net hosts over 70,000 Open Source Projects. See the people who have HELPED US provide better services: Click here: http://sourceforge.net/supporters.php _______________________________________________ hsqldb-developers mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/hsqldb-developers