This is an automated email from the ASF dual-hosted git repository.
asf-gitbox-commits pushed a commit to branch hsqldb2
in repository https://gitbox.apache.org/repos/asf/openoffice.git
commit 4d1e3c02fb8f963c2b1d625399383f273d643f10
Author: Pedro Giffuni <=>
AuthorDate: Wed Oct 28 00:19:46 2026 -0500
Update HSQLDB to version 2.5.0
This brings back CWS hsqldb19, cleaned and updated by Claude (free version).
We are using some built in compatibility, so the patch is nothing drastic.
Also all patches for the tarball itself are now obsolete.
While newer versions are available, version 2.50 has two advantages that
make it highly desirable:
- It still opens older 1.8.x databases.
- It doesn't require Java 11, or alterantive hacks, like newer versions of
the database.
for more information see:
https://www.hsqldb.org/
---
main/configure.ac | 10 +-
.../qa/connectivity/tools/CRMDatabase.java | 2 +-
main/connectivity/source/commontools/FValue.cxx | 10 +-
.../connectivity/source/drivers/hsqldb/HDriver.cxx | 78 +++-
.../source/drivers/hsqldb/HStorageAccess.cxx | 2 +
.../source/drivers/hsqldb/HStorageMap.cxx | 4 +-
.../source/inc/resource/hsqldb_res.hrc | 2 +
.../source/resource/conn_shared_res.src | 8 +-
main/dbaccess/source/core/api/KeySet.cxx | 2 +-
.../dbaccess/source/core/dataaccess/datasource.cxx | 4 +-
main/dbaccess/source/ui/browser/unodatbr.cxx | 8 +-
.../source/ui/control/FieldDescControl.cxx | 12 +-
main/external_deps.lst | 6 +-
main/hsqldb/makefile.mk | 19 +-
main/hsqldb/patches/i121754.patch | 430 ---------------------
main/hsqldb/patches/runfinalizers.patch | 22 --
main/hsqldb/patches/script.patch | 13 -
main/hsqldb/patches/text_tables.patch | 13 -
main/hsqldb/prj/d.lst | 2 +-
main/hsqldb/version.mk | 6 +-
20 files changed, 113 insertions(+), 540 deletions(-)
diff --git a/main/configure.ac b/main/configure.ac
index c9f8678070..4dd4ecea9c 100644
--- a/main/configure.ac
+++ b/main/configure.ac
@@ -4974,20 +4974,20 @@ if test -n "$with_system_hsqldb" -o -n
"$with_system_libs" && \
fi
AC_CHECK_FILE($HSQLDB_JAR, [],
[AC_MSG_ERROR(hsqldb.jar not found.)], [])
- AC_MSG_CHECKING([whether hsqldb is 1.8.0.x])
+ AC_MSG_CHECKING([whether hsqldb is 2.5.0 or newer])
export HSQLDB_JAR
if $PERL -e 'use Archive::Zip;
my $file = "$ENV{'HSQLDB_JAR'}";
my $zip = Archive::Zip->new( $file );
my $mf = $zip->contents ( "META-INF/MANIFEST.MF" );
- if ( $mf =~ m/Specification-Version: 1.8.*/ ) {
+ if ( $mf =~ m/Specification-Version: 2\.\d+\.\d+/ ) {
push @l, split(/\n/, $mf);
foreach my $line (@l) {
if ($line =~ m/Specification-Version:/) {
($t, $version) = split (/:/,$line);
$version =~ s/^\s//;
- ($a, $b, $c, $d) = split (/\./,$version);
- if ($c == "0" && $d > "8") {
+ ($a, $b, $c) = split (/\./,$version);
+ if ($a == 2 && ($b > 5 || ($b == 5 && $c >= 0))) {
exit 0;
} else {
exit 1;
@@ -4999,7 +4999,7 @@ if test -n "$with_system_hsqldb" -o -n
"$with_system_libs" && \
}'; then
AC_MSG_RESULT([yes])
else
- AC_MSG_ERROR([no, you need hsqldb >= 1.8.0.9 but < 1.8.1])
+ AC_MSG_ERROR([no, you need hsqldb >= 2.5.0])
fi
else
AC_MSG_RESULT([internal])
diff --git a/main/connectivity/qa/connectivity/tools/CRMDatabase.java
b/main/connectivity/qa/connectivity/tools/CRMDatabase.java
index 16e6536cc9..97115dc1ce 100644
--- a/main/connectivity/qa/connectivity/tools/CRMDatabase.java
+++ b/main/connectivity/qa/connectivity/tools/CRMDatabase.java
@@ -180,7 +180,7 @@ public class CRMDatabase
new HsqlColumnDescriptor( "Address",VARCHAR50),
new HsqlColumnDescriptor( "City",VARCHAR50),
new HsqlColumnDescriptor( "Postal",VARCHAR50),
- new HsqlColumnDescriptor( "Comment","LONGVARCHAR")} );
+ new HsqlColumnDescriptor( "Comment","CLOB")} );
m_database.createTable( table, true );
m_database.executeSQL( "INSERT INTO \"customers\" VALUES(1,'Food,
Inc.','Down Under','Melbourne','509','Prefered') " );
diff --git a/main/connectivity/source/commontools/FValue.cxx
b/main/connectivity/source/commontools/FValue.cxx
index e3f09e3ae0..a449c8c565 100644
--- a/main/connectivity/source/commontools/FValue.cxx
+++ b/main/connectivity/source/commontools/FValue.cxx
@@ -783,12 +783,6 @@ sal_Bool operator==(const DateTime& _rLH,const DateTime&
_rRH)
bool ORowSetValue::operator==(const ORowSetValue& _rRH) const
{
- if ( m_bNull != _rRH.isNull() )
- return false;
-
- if(m_bNull && _rRH.isNull())
- return true;
-
if ( m_eTypeKind != _rRH.m_eTypeKind )
{
switch(m_eTypeKind)
@@ -811,6 +805,10 @@ bool ORowSetValue::operator==(const ORowSetValue& _rRH)
const
}
return false;
}
+ if ( m_bNull != _rRH.isNull() )
+ return false;
+ if(m_bNull && _rRH.isNull())
+ return true;
bool bRet = false;
OSL_ENSURE(!m_bNull,"SHould not be null!");
diff --git a/main/connectivity/source/drivers/hsqldb/HDriver.cxx
b/main/connectivity/source/drivers/hsqldb/HDriver.cxx
index afec912298..cc73a39c79 100644
--- a/main/connectivity/source/drivers/hsqldb/HDriver.cxx
+++ b/main/connectivity/source/drivers/hsqldb/HDriver.cxx
@@ -40,6 +40,7 @@
#include <com/sun/star/frame/XDesktop.hpp>
#include <com/sun/star/lang/Locale.hpp>
#include <com/sun/star/util/XFlushable.hpp>
+#include <com/sun/star/task/XInteractionHandler.hpp>
#include "HTerminateListener.hxx"
#include "hsqldb/HCatalog.hxx"
#include "diagnose_ex.h"
@@ -48,6 +49,7 @@
#include <osl/process.h>
#include <connectivity/dbexception.hxx>
#include <comphelper/namedvaluecollection.hxx>
+#include <comphelper/interaction.hxx>
#include <unotools/confignode.hxx>
#include <unotools/ucbstreamhelper.hxx>
#include "resource/hsqldb_res.hrc"
@@ -58,6 +60,7 @@ namespace connectivity
{
//........................................................................
using namespace hsqldb;
+ using namespace ::comphelper;
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::sdbc;
using namespace ::com::sun::star::sdbcx;
@@ -65,9 +68,9 @@ namespace connectivity
using namespace ::com::sun::star::frame;
using namespace ::com::sun::star::lang;
using namespace ::com::sun::star::embed;
- using namespace ::com::sun::star::io;
+ using namespace ::com::sun::star::io;
+ using namespace ::com::sun::star::util;
using namespace ::com::sun::star::task;
- using namespace ::com::sun::star::util;
using namespace ::com::sun::star::reflection;
namespace hsqldb
@@ -182,6 +185,7 @@ namespace connectivity
{
::rtl::OUString sURL;
Reference<XStorage> xStorage;
+ Reference< XInteractionHandler > xInteraction;
const PropertyValue* pIter =
info.getConstArray();
const PropertyValue* pEnd = pIter +
info.getLength();
@@ -195,6 +199,10 @@ namespace connectivity
{
pIter->Value >>= sURL;
}
+ else if ( pIter->Name.equalsAscii("InteractionHandler") )
+ {
+ pIter->Value >>= xInteraction;
+ }
}
if ( !xStorage.is() || !sURL.getLength() )
@@ -229,7 +237,7 @@ namespace connectivity
// JDBC driver and driver's classpath
aProperties.put( "JavaDriverClass",
- ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"org.hsqldb.jdbcDriver" ) ) );
+ ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"org.hsqldb.jdbc.JDBCDriver" ) ) );
aProperties.put( "JavaDriverClassPath",
::rtl::OUString(
#ifdef SYSTEM_HSQLDB
@@ -250,6 +258,8 @@ namespace connectivity
// don't want to expose HSQLDB's schema capabilities which
exist since 1.8.0RC10
aProperties.put( "default_schema",
::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "true" ) ) );
+ aProperties.put( "hsqldb.default_table_type",
+ ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "cached" ) )
);
// security: permitted Java classes
NamedValue aPermittedClasses(
@@ -258,8 +268,11 @@ namespace connectivity
);
aProperties.put( "SystemProperties", Sequence< NamedValue >(
&aPermittedClasses, 1 ) );
- const ::rtl::OUString sProperties(
RTL_CONSTASCII_USTRINGPARAM( "properties" ) );
- ::rtl::OUString sMessage;
+ aProperties.put( "jdbc.interval_as_varchar",
::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "true" ) ) );
+ aProperties.put( "get_column_name",
::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "false" ) ) );
+
+ bool bAskUser = false,bModified = false;
+ ::rtl::OUString sProperties( RTL_CONSTASCII_USTRINGPARAM(
"properties" ) );
try
{
if ( !bIsNewDatabase &&
xStorage->isStreamElement(sProperties) )
@@ -282,10 +295,14 @@ namespace connectivity
{
sVersionString = sValue;
}
+ else if
( sLine.Equals("modified=yes",0,sizeof("modified=yes")-1) )
+ {
+
bModified = true;
+ }
else
{
- if ( sIniKey.Equals( "version" )
- && ( sVersionString.Len() == 0 )
+ if ( ( sVersionString.Len() == 0 )
+
&& sIniKey.Equals( "version" )
)
{
sVersionString = sValue;
@@ -295,14 +312,9 @@ namespace connectivity
if ( sVersionString.Len() )
{
const
sal_Int32 nMajor = sVersionString.GetToken(0,'.').ToInt32();
- const
sal_Int32 nMinor = sVersionString.GetToken(1,'.').ToInt32();
- const
sal_Int32 nMicro = sVersionString.GetToken(2,'.').ToInt32();
- if (
nMajor > 1
-
|| ( nMajor == 1 && nMinor > 8 )
-
|| ( nMajor == 1 && nMinor == 8 && nMicro > 0 ) )
+ if (
nMajor < 2 )
{
-
::connectivity::SharedResources aResources;
- sMessage =
aResources.getResourceString(STR_ERROR_NEW_VERSION);
+
bAskUser = true;
}
}
}
@@ -313,10 +325,31 @@ namespace connectivity
catch(Exception&)
{
}
- if ( sMessage.getLength() )
+
+ // check if database was shutdown correctly
before converting to new a version
+ if ( bModified && bAskUser )
{
+ ::connectivity::SharedResources
aResources;
+ const ::rtl::OUString sMessage =
aResources.getResourceString(STR_SHUTDOWN_REQUIRED);
::dbtools::throwGenericSQLException(sMessage ,*this);
}
+ // need to convert file, ask for user
approvement
+ if ( xInteraction.is() && bAskUser )
+ {
+ ::connectivity::SharedResources
aResources;
+ const ::rtl::OUString sRequest(
aResources.getResourceString(STR_CONVERT_TO_NEW_VERSION));
+ SQLException
aInfo(sRequest,*this,::rtl::OUString(),0,Any());
+ OInteractionRequest* pRequest = new
OInteractionRequest(makeAny(aInfo));
+ Reference< XInteractionRequest >
xRequest(pRequest);
+ OInteraction< XInteractionApprove >* pApprove = new
OInteraction< XInteractionApprove >();
+ pRequest->addContinuation(pApprove);
+ OInteraction< XInteractionDisapprove >* pDisApprove = new
OInteraction< XInteractionDisapprove >;
+ pRequest->addContinuation(pDisApprove);
+ xInteraction->handle(xRequest);
+ if ( !pDisApprove->wasSelected() )
+ bAskUser = false;
+ aProperties.put( "sql.enforce_size",
::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "false" ) ) );
+ }
// readonly?
Reference<XPropertySet>
xProp(xStorage,UNO_QUERY);
@@ -326,9 +359,12 @@ namespace connectivity
xProp->getPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("OpenMode")))
>>= nMode;
if ( (nMode & ElementModes::WRITE) !=
ElementModes::WRITE )
{
- aProperties.put( "readonly", ::rtl::OUString(
RTL_CONSTASCII_USTRINGPARAM( "true" ) ) );
+ bAskUser = true; // which means already added
+ //aProperties.put( "readonly", ::rtl::OUString(
RTL_CONSTASCII_USTRINGPARAM( "true" ) ) );
}
- }
+ } // if ( xProp.is() )
+ if ( bAskUser )
+ aProperties.put( "readonly", ::rtl::OUString(
RTL_CONSTASCII_USTRINGPARAM( "true" ) ) );
Sequence< PropertyValue > aConnectionArgs;
aProperties >>= aConnectionArgs;
@@ -340,11 +376,17 @@ namespace connectivity
try
{
xOrig = xDriver->connect( sConnectURL, aConnectionArgs );
+ }
+ catch(const SQLException& e)
+ {
+ StorageContainer::revokeStorage(sKey,NULL);
+ OSL_UNUSED(e);
+ throw;
}
catch(const Exception& e)
{
StorageContainer::revokeStorage(sKey,NULL);
- (void)e;
+ OSL_UNUSED(e);
throw;
}
diff --git a/main/connectivity/source/drivers/hsqldb/HStorageAccess.cxx
b/main/connectivity/source/drivers/hsqldb/HStorageAccess.cxx
index 91da80c0b6..5909c29c6c 100644
--- a/main/connectivity/source/drivers/hsqldb/HStorageAccess.cxx
+++ b/main/connectivity/source/drivers/hsqldb/HStorageAccess.cxx
@@ -435,6 +435,8 @@ void write_to_storage_stream_from_buffer( JNIEnv* env,
jobject /*obj_this*/, jst
if ( xOut.is() )
{
jbyte *buf = env->GetByteArrayElements(buffer,NULL);
+ OSL_ENSURE(len <= env->GetArrayLength(buffer),"Length is greater
than the buffer!");
+
if (JNI_FALSE != env->ExceptionCheck())
{
env->ExceptionClear();
diff --git a/main/connectivity/source/drivers/hsqldb/HStorageMap.cxx
b/main/connectivity/source/drivers/hsqldb/HStorageMap.cxx
index 5ba95f78b7..94b537c471 100644
--- a/main/connectivity/source/drivers/hsqldb/HStorageMap.cxx
+++ b/main/connectivity/source/drivers/hsqldb/HStorageMap.cxx
@@ -57,8 +57,8 @@ namespace connectivity
{
try
{
- m_xStream.clear();
- m_xSeek.clear();
+ m_xStream.clear();
+ m_xSeek.clear();
if ( m_xInputStream.is() )
{
m_xInputStream->closeInput();
diff --git a/main/connectivity/source/inc/resource/hsqldb_res.hrc
b/main/connectivity/source/inc/resource/hsqldb_res.hrc
index c76ab33519..e3cdec1adb 100644
--- a/main/connectivity/source/inc/resource/hsqldb_res.hrc
+++ b/main/connectivity/source/inc/resource/hsqldb_res.hrc
@@ -38,5 +38,7 @@
#define STR_NO_TABLENAME ( STR_HSQLDB_BASE + 4 )
#define STR_NO_DOCUMENTUI ( STR_HSQLDB_BASE + 5 )
#define STR_ERROR_NEW_VERSION ( STR_HSQLDB_BASE + 6 )
+#define STR_CONVERT_TO_NEW_VERSION ( STR_HSQLDB_BASE + 7 )
+#define STR_SHUTDOWN_REQUIRED ( STR_HSQLDB_BASE + 8 )
#endif // CONNECTIVITY_RESOURCE_HSQLDB_HRC
diff --git a/main/connectivity/source/resource/conn_shared_res.src
b/main/connectivity/source/resource/conn_shared_res.src
index 598e9dfd81..5391529aa5 100644
--- a/main/connectivity/source/resource/conn_shared_res.src
+++ b/main/connectivity/source/resource/conn_shared_res.src
@@ -629,9 +629,13 @@ String STR_NO_DOCUMENTUI
{
Text [ en-US ] = "The provided DocumentUI is not allowed to be NULL." ;
};
-String STR_ERROR_NEW_VERSION
+String STR_CONVERT_TO_NEW_VERSION
{
- Text = "The connection could not be established. The database was
created by a newer version of %PRODUCTNAME." ;
+ Text [ en-US ] = "The database file is stored in an old version. Do you
want to convert into the new version?" ;
+};
+String STR_SHUTDOWN_REQUIRED
+{
+ Text [ en-US ] = "The database file was not stored correctly by a
previous version of %PRODUCTNAME.\nPlease open the file with OpenOffice.org 3.3
or Oracle Open Office 3.3, then click the Tables icon and save." ;
};
// ********************************************************************** EOF
diff --git a/main/dbaccess/source/core/api/KeySet.cxx
b/main/dbaccess/source/core/api/KeySet.cxx
index 66ae3f79c8..bc8302d7db 100644
--- a/main/dbaccess/source/core/api/KeySet.cxx
+++ b/main/dbaccess/source/core/api/KeySet.cxx
@@ -1338,7 +1338,7 @@ sal_Bool OKeySet::previous_checked( sal_Bool i_bFetchRow )
if ( i_bFetchRow )
refreshRow();
}
- return m_aKeyIter != m_aKeyMap.begin();
+ return m_aKeyIter != m_aKeyMap.end() && m_aKeyIter != m_aKeyMap.begin();
}
//
-----------------------------------------------------------------------------
sal_Bool SAL_CALL OKeySet::previous( )
diff --git a/main/dbaccess/source/core/dataaccess/datasource.cxx
b/main/dbaccess/source/core/dataaccess/datasource.cxx
index 0db9aa7a38..5c0ad8419d 100644
--- a/main/dbaccess/source/core/dataaccess/datasource.cxx
+++ b/main/dbaccess/source/core/dataaccess/datasource.cxx
@@ -753,12 +753,14 @@ Reference< XConnection >
ODatabaseSource::buildLowLevelConnection(const ::rtl::O
if ( m_pImpl->isEmbeddedDatabase() )
{
sal_Int32 nCount = aDriverInfo.getLength();
- aDriverInfo.realloc(nCount + 2 );
+ aDriverInfo.realloc(nCount + 3 );
aDriverInfo[nCount].Name =
::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("URL"));
aDriverInfo[nCount++].Value <<=
m_pImpl->getURL();
aDriverInfo[nCount].Name =
::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Storage"));
Reference< css::document::XDocumentSubStorageSupplier>
xDocSup( m_pImpl->getDocumentSubStorageSupplier() );
aDriverInfo[nCount++].Value <<=
xDocSup->getDocumentSubStorage(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("database")),ElementModes::READWRITE);
+ aDriverInfo[nCount].Name =
::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("InteractionHandler"));
+ aDriverInfo[nCount++].Value <<=
m_pImpl->m_aContext.createComponent( "com.sun.star.task.InteractionHandler" );
}
if (nAdditionalArgs)
xReturn =
xManager->getConnectionWithInfo(m_pImpl->m_sConnectURL,
::comphelper::concatSequences(aUserPwd,aDriverInfo));
diff --git a/main/dbaccess/source/ui/browser/unodatbr.cxx
b/main/dbaccess/source/ui/browser/unodatbr.cxx
index c449820215..91965f9bf5 100644
--- a/main/dbaccess/source/ui/browser/unodatbr.cxx
+++ b/main/dbaccess/source/ui/browser/unodatbr.cxx
@@ -762,6 +762,7 @@ sal_Bool SbaTableQueryBrowser::InitializeGridModel(const
Reference< ::com::sun::
case DataType::BINARY:
case DataType::VARBINARY:
case DataType::LONGVARBINARY:
+ case DataType::BLOB:
aCurrentModelType =
::rtl::OUString::createFromAscii("TextField");
sDefaultProperty =
PROPERTY_DEFAULTTEXT;
break;
@@ -2191,13 +2192,12 @@ void SbaTableQueryBrowser::populateTree(const
Reference<XNameAccess>& _xNameAcce
{
if(
!m_pTreeView->getListBox().GetEntryPosByName(*pIter,_pParent))
{
+ Reference<XNameAccess>
xChild(_xNameAccess->getByName(*pIter),UNO_QUERY);
DBTreeListUserData* pEntryData = new
DBTreeListUserData;
pEntryData->eType = _eEntryType;
- if ( _eEntryType == etQuery )
+ if ( _eEntryType == etQuery && xChild.is() )
{
- Reference<XNameAccess>
xChild(_xNameAccess->getByName(*pIter),UNO_QUERY);
- if ( xChild.is() )
- pEntryData->eType =
etQueryContainer;
+ pEntryData->eType = etQueryContainer;
}
implAppendEntry( _pParent, *pIter, pEntryData,
pEntryData->eType );
}
diff --git a/main/dbaccess/source/ui/control/FieldDescControl.cxx
b/main/dbaccess/source/ui/control/FieldDescControl.cxx
index 78b45af7a3..15cba1c748 100644
--- a/main/dbaccess/source/ui/control/FieldDescControl.cxx
+++ b/main/dbaccess/source/ui/control/FieldDescControl.cxx
@@ -405,22 +405,25 @@ void OFieldDescControl::CheckScrollBars()
if (bNeedVScrollBar)
{
m_pVertScroll->Show();
- m_pVertScroll->SetRangeMax(nActive - nLastVisible);
+ m_pVertScroll->SetRangeMax(nActive);
+ m_pVertScroll->SetVisibleSize(nLastVisible);
// m_pVertScroll->SetThumbPos(0);
m_pVertScroll->SetPosSizePixel( Point(nNewHWidth, 0),
Size(nVScrollWidth, szOverallSize.Height()) );
}
else
{
+ m_nOldVThumb = 0;
m_pVertScroll->Hide();
m_pVertScroll->SetRangeMax(0);
m_pVertScroll->SetThumbPos(0);
}
-
+ m_nOldHThumb = 0;
if (bNeedHScrollBar)
{
m_pHorzScroll->Show();
- m_pHorzScroll->SetRangeMax((lMaxXPosition - lMaxXAvailable +
HSCROLL_STEP - 1 )/HSCROLL_STEP);
+ m_pHorzScroll->SetRangeMax((lMaxXPosition - lMaxXAvailable +
HSCROLL_STEP + 1 )/HSCROLL_STEP + 1);
+ m_pHorzScroll->SetVisibleSize(m_pHorzScroll->GetRangeMax() - 1);
// m_pHorzScroll->SetThumbPos(0);
m_pHorzScroll->SetPosSizePixel( Point(0, nNewVHeight),
Size(bNeedVScrollBar ? nNewHWidth : szOverallSize.Width(), nHScrollHeight) );
@@ -1209,7 +1212,8 @@ void OFieldDescControl::SetPosSize( Control** ppControl,
long nRow, sal_uInt16 n
if ( isRightAligned() )
{
Size aOwnSize = GetSizePixel();
- aPosition.X() = aOwnSize.Width() - aSize.Width();
+ long nVScrollWidth = m_pVertScroll->GetSizePixel().Width();
+ aPosition.X() = aOwnSize.Width() - aSize.Width() -
nVScrollWidth - LogicToPixel(Size(3, 0),MAP_APPFONT).Width();
}
else
aPosition.X() = CONTROL_WIDTH_1 + CONTROL_SPACING_X;
diff --git a/main/external_deps.lst b/main/external_deps.lst
index b7ddf2a260..bd9bb329e6 100644
--- a/main/external_deps.lst
+++ b/main/external_deps.lst
@@ -81,9 +81,9 @@ if (SYSTEM_LIBTEXTCAT != YES)
URL3 = https://software.wise-guys.nl/download/libtextcat-2.2.tar.gz
if (SOLAR_JAVA == TRUE)
- MD5 = 17410483b5b5f267aa18b7e00b65e6e0
- name = hsqldb_1_8_0.zip
- URL1 =
https://sourceforge.net/projects/hsqldb/files/hsqldb/hsqldb_1_8_0/hsqldb_1_8_0_10.zip
+ MD5 = 8140e899c4cdf04e31a06743230f8523
+ name = hsqldb-2.5.0.zip
+ URL1 =
https://downloads.sourceforge.net/project/hsqldb/hsqldb/hsqldb_2_5/hsqldb-2.5.0.zip
URL2 = $(OOO_EXTRAS)$(MD5)-$(name)
if ( true )
diff --git a/main/hsqldb/makefile.mk b/main/hsqldb/makefile.mk
index 0583bb51c7..6d34c7670a 100644
--- a/main/hsqldb/makefile.mk
+++ b/main/hsqldb/makefile.mk
@@ -40,30 +40,27 @@ ANT_BUILDFILE=build$/build.xml
.IF "$(SOLAR_JAVA)" != ""
# --- Files --------------------------------------------------------
-TARFILE_NAME=hsqldb_$(HSQLDB_VERSION)
-TARFILE_MD5=17410483b5b5f267aa18b7e00b65e6e0
+TARFILE_NAME=hsqldb-$(HSQLDB_VERSION)
+TARFILE_MD5=8140e899c4cdf04e31a06743230f8523
-TARFILE_ROOTDIR=hsqldb
+TARFILE_ROOTDIR=hsqldb-$(HSQLDB_VERSION)$/hsqldb
CONVERTFILES=build$/build.xml \
- src$/org$/hsqldb$/persist$/HsqlDatabaseProperties.java \
- src$/org$/hsqldb$/Library.java
+ src$/org$/hsqldb$/persist$/HsqlDatabaseProperties.java
-PATCH_FILES=patches$/i121754.patch patches$/script.patch
patches$/runfinalizers.patch patches$/text_tables.patch
+PATCH_FILES=
-# hsqldb's build.xml javac tasks specify no source/target; pin them so bytecode
-# stays Java 8 compatible regardless of the (possibly much newer) build JDK.
JAVAC_SRCTGT=-Dant.build.javac.source=1.8 -Dant.build.javac.target=1.8
.IF "$(JAVACISGCJ)"=="yes"
JAVA_HOME=
.EXPORT : JAVA_HOME
-BUILD_ACTION=$(ANT) -Dbuild.label="build-$(RSCREVISION)" -Dbuild.compiler=gcj
$(JAVAC_SRCTGT) -f $(ANT_BUILDFILE) jar
+BUILD_ACTION=$(ANT) -Dbuild.label="build-$(RSCREVISION)" -Dbuild.compiler=gcj
$(JAVAC_SRCTGT) -f $(ANT_BUILDFILE) hsqldb
.ELSE
.IF "$(debug)"!=""
-BUILD_ACTION=$(ANT) -Dbuild.label="build-$(RSCREVISION)" -Dbuild.debug="on"
$(JAVAC_SRCTGT) -f $(ANT_BUILDFILE) jar
+BUILD_ACTION=$(ANT) -Dbuild.label="build-$(RSCREVISION)" -Dbuild.debug="on"
$(JAVAC_SRCTGT) -f $(ANT_BUILDFILE) hsqldb
.ELSE
-BUILD_ACTION=$(ANT) -Dbuild.label="build-$(RSCREVISION)" $(JAVAC_SRCTGT) -f
$(ANT_BUILDFILE) jar
+BUILD_ACTION=$(ANT) -Dbuild.label="build-$(RSCREVISION)" $(JAVAC_SRCTGT) -f
$(ANT_BUILDFILE) hsqldb
.ENDIF
.ENDIF
diff --git a/main/hsqldb/patches/i121754.patch
b/main/hsqldb/patches/i121754.patch
deleted file mode 100644
index fe3d6fb9e5..0000000000
--- a/main/hsqldb/patches/i121754.patch
+++ /dev/null
@@ -1,430 +0,0 @@
-diff -urbwB ext_sources/hsqldb/build/build.xml
ext_sources/hsqldb_1_8_0_11/build/build.xml
---- misc/hsqldb/build/build.xml 2008-06-01 23:56:57.000000000 +0200
-+++ misc/build/hsqldb/build/build.xml 2013-07-05 23:25:40.000000000 +0200
-@@ -1,6 +1,6 @@
- <?xml version="1.0"?>
--<!-- author [email protected] 2001 - 2008 -->
--<!-- additional targets by [email protected] 2004 - 2008 -->
-+<!-- author [email protected] 2001 - 2009 -->
-+<!-- additional targets by [email protected] 2004 - 2009 -->
-
- <project name="hsqldb" default="help" basedir="../">
- <!-- This loads properties in the same exact way as if you ran
-@@ -14,10 +14,10 @@
- Do not address questions about property file(s) to the
- hsqldb community. -->
- <property file='build/build.properties'/>
-- <property name="hsqldb.version" value="1.8.0.10"/>
-+ <property name="hsqldb.version" value="1.8.0.11"/>
-
- <tstamp>
-- <format property="_tmpstamp" pattern="yyyy/MM/dd-hh:mm:ss"
-+ <format property="_tmpstamp" pattern="yyyy/MM/dd-HH:mm:ss"
- locale="en"/>
- </tstamp>
-
-@@ -26,7 +26,7 @@
- <property name="hsqldb.title" value="HSQLDB"/>
- <property name="hsqldb.vendor" value="The HSQLDB Development Group"/>
- <property name="src" value="${basedir}/src"/>
-- <property name="build.debug" value="off"/>
-+ <property name="build.debug" value="false"/>
-
- <target name="init">
- </target>
-@@ -213,10 +213,11 @@
- </java>
- </target>
-
-- <target name="switchtojdk14" depends="switches"
-+ <target name="switchtojdk14" depends="switchtojdk13"
- description="self explanatory" if="ant.java.iscjava14">
- <java classname="org.hsqldb.util.CodeSwitcher" classpath="classes" >
- <arg file="${src}/org/hsqldb/lib/java/JavaSystem.java"/>
-+ <arg file="${src}/org/hsqldb/jdbcDriver.java"/>
- <arg file="${src}/org/hsqldb/lib/HsqlTimer.java"/>
- <arg file="${src}/org/hsqldb/jdbc/jdbcBlob.java"/>
- <arg file="${src}/org/hsqldb/jdbc/jdbcDatabaseMetaData.java"/>
-@@ -251,6 +252,7 @@
- <target name="switchtojdk16" depends="switchtojdk14"
- description="self explanatory" if="ant.java.iscjava16">
- <java classname="org.hsqldb.util.CodeSwitcher" classpath="classes" >
-+ <arg file="${src}/org/hsqldb/jdbcDriver.java"/>
- <arg file="${src}/org/hsqldb/lib/java/JavaSystem.java"/>
- <arg file="${src}/org/hsqldb/lib/HsqlTimer.java"/>
- <arg file="${src}/org/hsqldb/jdbc/jdbcBlob.java"/>
-diff -urbwB ext_sources/hsqldb/src/org/hsqldb/Expression.java
ext_sources/hsqldb_1_8_0_11/src/org/hsqldb/Expression.java
---- misc/hsqldb/src/org/hsqldb/Expression.java 2008-05-27 17:15:05.000000000
+0200
-+++ misc/build/hsqldb/src/org/hsqldb/Expression.java 2013-07-05
23:40:51.000000000 +0200
-@@ -807,6 +807,14 @@
-
- case COUNT :
- buf.append(' ').append(Token.T_COUNT).append('(');
-+
-+ if ("(*)".equals(left)) {
-+ buf.append('*');
-+ } else {
-+ buf.append(left);
-+ }
-+
-+ buf.append(')');
- break;
-
- case SUM :
-@@ -858,11 +866,15 @@
- buf.append(' ').append(Token.T_VAR_SAMP).append('(');
- buf.append(left).append(')');
- break;
-- }
-
-+ default :
- throw Trace.error(Trace.EXPRESSION_NOT_SUPPORTED);
- }
-
-+ // changes used in OpenOffice 3.4 have been incorporated
-+ return buf.toString();
-+ }
-+
- private String describe(Session session, int blanks) {
-
- int lIType;
-@@ -1523,6 +1535,12 @@
- return columnName;
- }
-
-+ if (isAggregate(exprType)) {
-+ try {
-+ return getDDL();
-+ } catch (Exception e) {}
-+ }
-+
- return "";
- }
-
-diff -urbwB ext_sources/hsqldb/src/org/hsqldb/jdbc/jdbcCallableStatement.java
ext_sources/hsqldb_1_8_0_11/src/org/hsqldb/jdbc/jdbcCallableStatement.java
---- misc/hsqldb/src/org/hsqldb/jdbc/jdbcCallableStatement.java 2008-03-20
02:44:28.000000000 +0100
-+++ misc/build/hsqldb/src/org/hsqldb/jdbc/jdbcCallableStatement.java
2013-07-05 23:45:50.000000000 +0200
-@@ -3376,7 +3376,26 @@
- {
- throw new UnsupportedOperationException("Not supported yet.");
- }
--*/
-
-+ public <T>T getObject(int parameterIndex,
-+ Class<T> type) throws SQLException {
-+ return (T) this.getObject(parameterIndex);
-+ }
-+
-+ public <T>T getObject(String parameterName,
-+ Class<T> type) throws SQLException {
-+ return getObject(this.findParameterIndex(parameterName), type);
-+ }
-+
-+ public void closeOnCompletion() throws SQLException {
-+ throw new UnsupportedOperationException("Not supported yet.");
-+ }
-+
-+ public boolean isCloseOnCompletion() throws SQLException {
-+ throw new UnsupportedOperationException("Not supported yet.");
-+ }
-+
-+*/
- //#endif JAVA6
-+
- }
-diff -urbwB ext_sources/hsqldb/src/org/hsqldb/jdbc/jdbcConnection.java
ext_sources/hsqldb_1_8_0_11/src/org/hsqldb/jdbc/jdbcConnection.java
---- misc/hsqldb/src/org/hsqldb/jdbc/jdbcConnection.java 2008-03-20
02:44:28.000000000 +0100
-+++ misc/build/hsqldb/src/org/hsqldb/jdbc/jdbcConnection.java 2013-07-05
23:46:02.000000000 +0200
-@@ -2794,6 +2794,36 @@
- {
- throw new UnsupportedOperationException("Not supported yet.");
- }
-+
-+ public int getNetworkTimeout() throws SQLException {
-+ return 0;
-+ }
-+
-+ public void setNetworkTimeout(java.util.concurrent.Executor executor,
-+ int milliseconds) throws SQLException {
-+
-+ checkClosed();
-+
-+ throw Util.notSupported();
-+ }
-+
-+ public void setSchema(String schema) throws SQLException {
-+ checkClosed();
-+
-+ throw Util.notSupported();
-+ }
-+
-+ public String getSchema() throws SQLException {
-+ checkClosed();
-+
-+ throw Util.notSupported();
-+ }
-+ public void abort(
-+ java.util.concurrent.Executor executor) throws SQLException {
-+ checkClosed();
-+
-+ throw Util.notSupported();
-+ }
- */
-
- //#endif JAVA6
-diff -urbwB ext_sources/hsqldb/src/org/hsqldb/jdbc/jdbcDatabaseMetaData.java
ext_sources/hsqldb_1_8_0_11/src/org/hsqldb/jdbc/jdbcDatabaseMetaData.java
---- misc/hsqldb/src/org/hsqldb/jdbc/jdbcDatabaseMetaData.java 2008-03-20
02:44:28.000000000 +0100
-+++ misc/build/hsqldb/src/org/hsqldb/jdbc/jdbcDatabaseMetaData.java
2013-07-05 23:46:18.000000000 +0200
-@@ -5694,7 +5694,17 @@
- {
- throw new UnsupportedOperationException("Not supported yet.");
- }
--*/
-
-+ public ResultSet getPseudoColumns(
-+ String catalog, String schemaPattern, String tableNamePattern,
-+ String columnNamePattern) throws SQLException {
-+ throw Util.notSupported();
-+ }
-+
-+ public boolean generatedKeyAlwaysReturned() throws SQLException {
-+ return true;
-+ }
-+
-+*/
- //#endif JAVA6
- }
-diff -urbwB ext_sources/hsqldb/src/org/hsqldb/jdbc/jdbcDataSource.java
ext_sources/hsqldb_1_8_0_11/src/org/hsqldb/jdbc/jdbcDataSource.java
---- misc/hsqldb/src/org/hsqldb/jdbc/jdbcDataSource.java 2008-05-28
22:23:02.000000000 +0200
-+++ misc/build/hsqldb/src/org/hsqldb/jdbc/jdbcDataSource.java 2013-07-05
23:46:39.000000000 +0200
-@@ -322,6 +322,11 @@
- {
- throw new UnsupportedOperationException("Not supported yet.");
- }
-+
-+ public java.util.logging.Logger getParentLogger()
-+ throws java.sql.SQLFeatureNotSupportedException {
-+ throw (java.sql.SQLFeatureNotSupportedException) Util.notSupported();
-+ }
- */
-
- //#endif JAVA6
-diff -urbwB ext_sources/hsqldb/src/org/hsqldb/jdbc/jdbcPreparedStatement.java
ext_sources/hsqldb_1_8_0_11/src/org/hsqldb/jdbc/jdbcPreparedStatement.java
---- misc/hsqldb/src/org/hsqldb/jdbc/jdbcPreparedStatement.java 2008-03-20
02:44:28.000000000 +0100
-+++ misc/build/hsqldb/src/org/hsqldb/jdbc/jdbcPreparedStatement.java
2013-07-05 23:46:54.000000000 +0200
-@@ -2403,6 +2403,15 @@
- {
- throw new UnsupportedOperationException("Not supported yet.");
- }
-+
-+ public void closeOnCompletion() throws SQLException {
-+ checkClosed();
-+ }
-+
-+ public boolean isCloseOnCompletion() throws SQLException {
-+ checkClosed();
-+ return false;
-+ }
- */
-
- //#endif JAVA6
-diff -urbwB ext_sources/hsqldb/src/org/hsqldb/jdbc/jdbcResultSet.java
ext_sources/hsqldb_1_8_0_11/src/org/hsqldb/jdbc/jdbcResultSet.java
---- misc/hsqldb/src/org/hsqldb/jdbc/jdbcResultSet.java 2008-03-20
02:44:28.000000000 +0100
-+++ misc/build/hsqldb/src/org/hsqldb/jdbc/jdbcResultSet.java 2013-07-05
23:47:15.000000000 +0200
-@@ -5325,7 +5325,16 @@
- {
- throw new UnsupportedOperationException("Not supported yet.");
- }
--*/
-
-+ public <T>T getObject(int columnIndex, Class<T> type) throws SQLException
{
-+ return (T) getObject(columnIndex);
-+ }
-+
-+ public <T>T getObject(String columnLabel,
-+ Class<T> type) throws SQLException {
-+ return getObject(findColumn(columnLabel), type);
-+ }
-+
-+*/
- //#endif JAVA6
- }
-diff -urbwB ext_sources/hsqldb/src/org/hsqldb/jdbc/jdbcStatement.java
ext_sources/hsqldb_1_8_0_11/src/org/hsqldb/jdbc/jdbcStatement.java
---- misc/hsqldb/src/org/hsqldb/jdbc/jdbcStatement.java 2008-03-20
02:44:28.000000000 +0100
-+++ misc/build/hsqldb/src/org/hsqldb/jdbc/jdbcStatement.java 2013-07-05
23:47:29.000000000 +0200
-@@ -1608,6 +1608,16 @@
- {
- throw new UnsupportedOperationException("Not supported yet.");
- }
-+
-+ public void closeOnCompletion() throws SQLException {
-+ checkClosed();
-+ }
-+
-+ public boolean isCloseOnCompletion() throws SQLException {
-+ checkClosed();
-+ return false;
-+ }
-+
- */
- //#endif JAVA6
- }
-diff -urbwB ext_sources/hsqldb/src/org/hsqldb/jdbcDriver.java
ext_sources/hsqldb_1_8_0_11/src/org/hsqldb/jdbcDriver.java
---- misc/hsqldb/src/org/hsqldb/jdbcDriver.java 2006-04-11 17:03:24.000000000
+0200
-+++ misc/build/hsqldb/src/org/hsqldb/jdbcDriver.java 2013-07-05
23:48:06.000000000 +0200
-@@ -321,4 +321,16 @@
- DriverManager.registerDriver(new jdbcDriver());
- } catch (Exception e) {}
- }
-+
-+//#ifdef JAVA6
-+/*
-+ public java.util.logging
-+ .Logger getParentLogger() throws java.sql
-+ .SQLFeatureNotSupportedException {
-+ throw new UnsupportedOperationException("Not supported yet.");
-+ }
-+*/
-+
-+//#endif
-+
- }
-diff -urbwB ext_sources/hsqldb/src/org/hsqldb/lib/StringComparator.java
ext_sources/hsqldb_1_8_0_11/src/org/hsqldb/lib/StringComparator.java
---- misc/hsqldb/src/org/hsqldb/lib/StringComparator.java 2013-07-06
00:32:59.000000000 +0200
-+++ misc/build/hsqldb/src/org/hsqldb/lib/StringComparator.java 2013-07-06
00:09:04.000000000 +0200
-@@ -0,0 +1,53 @@
-+/* Copyright (c) 2001-2008, The HSQL Development Group
-+ * All rights reserved.
-+ *
-+ * Redistribution and use in source and binary forms, with or without
-+ * modification, are permitted provided that the following conditions are met:
-+ *
-+ * Redistributions of source code must retain the above copyright notice, this
-+ * list of conditions and the following disclaimer.
-+ *
-+ * Redistributions in binary form must reproduce the above copyright notice,
-+ * this list of conditions and the following disclaimer in the documentation
-+ * and/or other materials provided with the distribution.
-+ *
-+ * Neither the name of the HSQL Development Group nor the names of its
-+ * contributors may be used to endorse or promote products derived from this
-+ * software without specific prior written permission.
-+ *
-+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
-+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-+ * ARE DISCLAIMED. IN NO EVENT SHALL HSQL DEVELOPMENT GROUP, HSQLDB.ORG,
-+ * OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
-+ * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
-+ * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
-+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
-+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
THIS
-+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-+ */
-+
-+
-+package org.hsqldb.lib;
-+
-+public class StringComparator implements ObjectComparator {
-+
-+ public int compare(Object a, Object b) {
-+
-+ // handle nulls
-+ if (a == b) {
-+ return 0;
-+ }
-+
-+ if (a == null) {
-+ return -1;
-+ }
-+
-+ if (b == null) {
-+ return 1;
-+ }
-+
-+ return ((String) a).compareTo((String) b);
-+ }
-+}
-diff -urbwB ext_sources/hsqldb/src/org/hsqldb/Library.java
ext_sources/hsqldb_1_8_0_11/src/org/hsqldb/Library.java
---- misc/hsqldb/src/org/hsqldb/Library.java 2006-07-17 00:29:33.000000000
+0200
-+++ misc/build/hsqldb/src/org/hsqldb/Library.java 2013-07-05
23:51:13.000000000 +0200
-@@ -1957,7 +1957,7 @@
- functionMap.put("bitand", bitand);
- functionMap.put("bitlength", bitLength);
- functionMap.put("bitor", bitor);
-- functionMap.put("bitxor", bitor);
-+ functionMap.put("bitxor", bitxor);
- functionMap.put("character", character);
- functionMap.put("concat", concat);
- functionMap.put("cot", cot);
-diff -urbwB
ext_sources/hsqldb/src/org/hsqldb/persist/HsqlDatabaseProperties.java
ext_sources/hsqldb_1_8_0_11/src/org/hsqldb/persist/HsqlDatabaseProperties.java
---- misc/hsqldb/src/org/hsqldb/persist/HsqlDatabaseProperties.java
2008-03-17 17:05:41.000000000 +0100
-+++ misc/build/hsqldb/src/org/hsqldb/persist/HsqlDatabaseProperties.java
2013-07-05 23:52:14.000000000 +0200
-@@ -429,6 +429,7 @@
- setProperty(hsqldb_log_size, 10);
- setProperty(sql_enforce_strict_size, true);
- setProperty(hsqldb_nio_data_file, false);
-+ setProperty(hsqldb_lock_file, true);
- }
-
- // OOo end
-diff -urbwB ext_sources/hsqldb/src/org/hsqldb/Select.java
ext_sources/hsqldb_1_8_0_11/src/org/hsqldb/Select.java
---- misc/hsqldb/src/org/hsqldb/Select.java 2007-07-17 18:14:09.000000000
+0200
-+++ misc/build/hsqldb/src/org/hsqldb/Select.java 2013-07-05
23:57:48.000000000 +0200
-@@ -33,7 +33,7 @@
- *
- * For work added by the HSQL Development Group:
- *
-- * Copyright (c) 2001-2008, The HSQL Development Group
-+ * Copyright (c) 2001-2005, The HSQL Development Group
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
-@@ -1255,6 +1255,7 @@
- for (int i = 0; i < iResultLen; i++) {
- e = exprColumns[i];
- rmd.colTypes[i] = e.getDataType();
-+ rmd.classNames[i] = e.getValueClassName();
- rmd.colSizes[i] = e.getColumnSize();
- rmd.colScales[i] = e.getColumnScale();
- rmd.colLabels[i] = e.getAlias();
-@@ -1263,6 +1264,7 @@
- rmd.colNames[i] = e.getColumnName();
-
- if (rmd.isTableColumn(i)) {
-+ rmd.schemaNames[i] = e.getTableSchemaName();
- rmd.colNullable[i] = e.nullability;
- rmd.isIdentity[i] = e.isIdentity;
- rmd.isWritable[i] = e.isWritable;
-diff -urbwB ext_sources/hsqldb/src/org/hsqldb/Table.java
ext_sources/hsqldb_1_8_0_11/src/org/hsqldb/Table.java
---- misc/hsqldb/src/org/hsqldb/Table.java 2007-10-19 23:59:07.000000000
+0200
-+++ misc/build/hsqldb/src/org/hsqldb/Table.java 2013-07-05
23:58:46.000000000 +0200
-@@ -149,10 +149,10 @@
- Constraint[] constraintList; // constrainst for the
table
- HsqlArrayList[] triggerLists; // array of trigger
lists
- private int[] colTypes; // fredt - types of
columns
-- private int[] colSizes; // fredt - copy of SIZE
values for columns
-+ int[] colSizes; // fredt - copy of SIZE
values for columns
- private int[] colScales; // fredt - copy of
SCALE values for columns
- private boolean[] colNullable; // fredt - modified
copy of isNullable() values
-- private Expression[] colDefaults; // fredt - expressions
of DEFAULT values
-+ Expression[] colDefaults; // fredt - expressions
of DEFAULT values
- private int[] defaultColumnMap; // fred - holding
0,1,2,3,...
- private boolean hasDefaultValues; //fredt - shortcut for
above
- boolean sqlEnforceSize; // inherited from the
database -
-diff -urbwB ext_sources/hsqldb/src/org/hsqldb/TableWorks.java
ext_sources/hsqldb_1_8_0_11/src/org/hsqldb/TableWorks.java
---- misc/hsqldb/src/org/hsqldb/TableWorks.java 2007-01-14 06:48:16.000000000
+0100
-+++ misc/build/hsqldb/src/org/hsqldb/TableWorks.java 2013-07-05
23:59:03.000000000 +0200
-@@ -670,7 +670,10 @@
- // default expressions can change
- oldCol.setType(newCol);
- oldCol.setDefaultExpression(newCol.getDefaultExpression());
-- table.setColumnTypeVars(colIndex);
-+
-+ table.colSizes[colIndex] = oldCol.getSize();
-+ table.colDefaults[colIndex] = oldCol.getDefaultExpression();
-+
- table.resetDefaultsFlag();
-
- return;
diff --git a/main/hsqldb/patches/runfinalizers.patch
b/main/hsqldb/patches/runfinalizers.patch
deleted file mode 100644
index dfeafdfee2..0000000000
--- a/main/hsqldb/patches/runfinalizers.patch
+++ /dev/null
@@ -1,22 +0,0 @@
---- misc/build/hsqldb/src/org/hsqldb/lib/java/JavaSystem.java
-+++ misc/build/hsqldb/src/org/hsqldb/lib/java/JavaSystem.java
-@@ -160,7 +160,7 @@
- public static void runFinalizers() {
-
- //#ifdef JAVA2FULL
-- System.runFinalizersOnExit(true);
-+ // System.runFinalizersOnExit(boolean) was removed in Java 11+;
dropped for modern JDK compatibility
-
- //#endif
- }
---- misc/build/hsqldb/src/org/hsqldb/lib/HsqlArrayList.java
-+++ misc/build/hsqldb/src/org/hsqldb/lib/HsqlArrayList.java
-@@ -57,7 +57,7 @@
- Reporter() {
-
- try {
-- System.runFinalizersOnExit(true);
-+ // System.runFinalizersOnExit(boolean) was removed in Java
11+; dropped for modern JDK compatibility
- } catch (SecurityException e) {}
- }
-
diff --git a/main/hsqldb/patches/script.patch b/main/hsqldb/patches/script.patch
deleted file mode 100644
index dc722d8198..0000000000
--- a/main/hsqldb/patches/script.patch
+++ /dev/null
@@ -1,13 +0,0 @@
-diff -ru misc/hsqldb/src/org/hsqldb/DatabaseCommandInterpreter.java
misc/build/hsqldb/src/org/hsqldb/DatabaseCommandInterpreter.java
---- misc/hsqldb/src/org/hsqldb/DatabaseCommandInterpreter.java 2008-05-27
14:26:44.000000000 +0200
-+++ misc/build/hsqldb/src/org/hsqldb/DatabaseCommandInterpreter.java
2023-02-19 15:28:44.167555700 +0100
-@@ -402,6 +402,9 @@
- if (tokenizer.getType() != Types.VARCHAR) {
- throw Trace.error(Trace.INVALID_IDENTIFIER);
- }
-+ if (session.isProcessingScript() ||
session.isProcessingLog()) {
-+ return new Result(ResultConstants.UPDATECOUNT);
-+ }
-
- dsw = new ScriptWriterText(database, token, true, true, true);
-
diff --git a/main/hsqldb/patches/text_tables.patch
b/main/hsqldb/patches/text_tables.patch
deleted file mode 100644
index 896c8dc3ce..0000000000
--- a/main/hsqldb/patches/text_tables.patch
+++ /dev/null
@@ -1,13 +0,0 @@
-diff -ru misc/hsqldb/src/org/hsqldb/persist/Log.java
misc/build/hsqldb/src/org/hsqldb/persist/Log.java
---- misc/hsqldb/src/org/hsqldb/persist/Log.java 2008-03-14
16:47:42.000000000 +0100
-+++ misc/build/hsqldb/src/org/hsqldb/persist/Log.java 2026-09-08
22:40:39.681242533 +0200
-@@ -763,7 +763,7 @@
-
- closeTextCache(table);
-
-- if (!properties.isPropertyTrue(
-+ if (database.isStoredFileAccess() || !properties.isPropertyTrue(
- HsqlDatabaseProperties.textdb_allow_full_path)) {
- if (source.indexOf("..") != -1) {
- throw (Trace.error(Trace.ACCESS_IS_DENIED, source));
-
diff --git a/main/hsqldb/prj/d.lst b/main/hsqldb/prj/d.lst
index 8801f4fecf..38758af25b 100644
--- a/main/hsqldb/prj/d.lst
+++ b/main/hsqldb/prj/d.lst
@@ -1 +1 @@
-..\%__SRC%\misc\build\hsqldb\lib\hsqldb.jar %_DEST%\bin%_EXT%\hsqldb.jar
+..\%__SRC%\misc\build\hsqldb-2.5.0\hsqldb\lib\hsqldb.jar
%_DEST%\bin%_EXT%\hsqldb.jar
diff --git a/main/hsqldb/version.mk b/main/hsqldb/version.mk
index 2ca6ca2df5..9413eaef6f 100644
--- a/main/hsqldb/version.mk
+++ b/main/hsqldb/version.mk
@@ -20,7 +20,7 @@
# *************************************************************
# when you want to change the HSQLDB version, you must update the d.lst
# in the HSQLDB_thon project accordingly !!!
-HSQLDB_MAJOR=1
-HSQLDB_MINOR=8
+HSQLDB_MAJOR=2
+HSQLDB_MINOR=5
HSQLDB_MICRO=0
-HSQLDB_VERSION=$(HSQLDB_MAJOR)_$(HSQLDB_MINOR)_$(HSQLDB_MICRO)
+HSQLDB_VERSION=$(HSQLDB_MAJOR).$(HSQLDB_MINOR).$(HSQLDB_MICRO)