summaryrefslogtreecommitdiff
path: root/connectivity
diff options
context:
space:
mode:
authorTamas Bunth <tamas.bunth@collabora.co.uk>2018-01-08 15:57:39 +0100
committerAndras Timar <andras.timar@collabora.com>2018-03-25 17:38:25 +0200
commit7907f2c478c4669962ecb60b85c3d007f4b07deb (patch)
tree1a1de0ba1258dd033981099d2c4452425bacfe23 /connectivity
parent0f4e12d67edddef30fab4c2b5dac9c6adda32428 (diff)
Add HSQLDB schema import
It can be enabled by initializing the DBACCESS_HSQL_MIGRATION variable. Create new library "dbahsql" which is responsible for migrating the embedded hsql database to any database covered by sdbc. The hsqldb schema is stored in a file named "script" in form of SQL statements. The SQL statements used by DBMS's differ mostly by the defined types. Because of that, only the create statements need to be parsed, alter statements will work (with a little luck) without actually modifying it. User / security settings which can occur in the script file (e.g. GRANT statements) are dropped. Statements starting with SET are also dropped (they are hsql specific stuff) Change-Id: I6a22942e8a9a76765f80e50f0ad68f4d72e1ff9d Reviewed-on: https://gerrit.libreoffice.org/48260 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tamás Bunth <btomi96@gmail.com> (cherry picked from commit 95bece38ac5c943657ad959cad148c84a91d45a4)
Diffstat (limited to 'connectivity')
-rw-r--r--connectivity/source/drivers/firebird/Connection.cxx8
1 files changed, 3 insertions, 5 deletions
diff --git a/connectivity/source/drivers/firebird/Connection.cxx b/connectivity/source/drivers/firebird/Connection.cxx
index 32e314029f7f..5d1a7957b5e2 100644
--- a/connectivity/source/drivers/firebird/Connection.cxx
+++ b/connectivity/source/drivers/firebird/Connection.cxx
@@ -205,11 +205,9 @@ void Connection::construct(const ::rtl::OUString& url, const Sequence< PropertyV
}
else
{
- ::connectivity::SharedResources aResources;
- // TODO FIXME: this does _not_ look like the right error message
- const OUString sMessage = aResources.getResourceString(STR_ERROR_NEW_VERSION);
- ::dbtools::throwGenericSQLException(sMessage ,*this);
-
+ // There might be files which are not firebird databases.
+ // This is not a problem.
+ bIsNewDatabase = true;
}
}
// TODO: Get DB properties from XML