diff options
author | Andreas Bille <abi@openoffice.org> | 2001-05-14 07:09:51 +0000 |
---|---|---|
committer | Andreas Bille <abi@openoffice.org> | 2001-05-14 07:09:51 +0000 |
commit | 08bd7a47180176a80cb8b10e046c56ca659db12e (patch) | |
tree | 47000dc471b4b3684ce34301101f0763e270b1db /ucb/source | |
parent | 71d18a67367c272e4e222a2f5a162458a8cd51d1 (diff) |
Bug fixed ( First element in resultset not shown )
and improved version ( unnecessary assignment ) of Darryl Gove`s patch.
Diffstat (limited to 'ucb/source')
-rw-r--r-- | ucb/source/ucp/file/filrset.cxx | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/ucb/source/ucp/file/filrset.cxx b/ucb/source/ucp/file/filrset.cxx index 47c57573c133..f4c06edabfce 100644 --- a/ucb/source/ucp/file/filrset.cxx +++ b/ucb/source/ucp/file/filrset.cxx @@ -2,9 +2,9 @@ * * $RCSfile: filrset.cxx,v $ * - * $Revision: 1.8 $ + * $Revision: 1.9 $ * - * last change: $Author: abi $ $Date: 2001-05-14 07:40:00 $ + * last change: $Author: abi $ $Date: 2001-05-14 08:09:51 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -641,20 +641,21 @@ XResultSet_impl::getRow( sal_Bool SAL_CALL XResultSet_impl::absolute( sal_Int32 row ) throw( sdbc::SQLException, uno::RuntimeException) { - if( ! row ) + if( !row ) throw sdbc::SQLException(); if( row >= 0 ) { - m_nRow = -1; - while( row-- ) next(); + m_nRow = row - 1; + if( row >= m_aItems.size() ) + while( row-- && OneMore() ) + ; } else { row = - row - 1; last(); - while( row-- ) - --m_nRow; + while( row-- ) --m_nRow; } return 0<= m_nRow && m_nRow < m_aItems.size(); @@ -662,6 +663,7 @@ sal_Bool SAL_CALL XResultSet_impl::absolute( sal_Int32 row ) + sal_Bool SAL_CALL XResultSet_impl::relative( sal_Int32 row ) |