summaryrefslogtreecommitdiff
path: root/connectivity
diff options
context:
space:
mode:
authorLionel Elie Mamane <lionel@mamane.lu>2011-09-14 10:50:48 +0200
committerLionel Elie Mamane <lionel@mamane.lu>2011-11-17 21:15:29 +0100
commit878f6b5bc0ab70e66b3ba91b7d069dc78700cd20 (patch)
tree483e38fd1585e5f475f3aa6a7e4e1353cc357ae8 /connectivity
parentb31ca7df75be7a8b86926d9cf385ee9c4f04daca (diff)
Throw SQLSTATE="IM001" for "not supported"
enables write access to tables with LibreOffice 3.5
Diffstat (limited to 'connectivity')
-rw-r--r--connectivity/source/drivers/postgresql/pq_sequenceresultset.cxx7
1 files changed, 6 insertions, 1 deletions
diff --git a/connectivity/source/drivers/postgresql/pq_sequenceresultset.cxx b/connectivity/source/drivers/postgresql/pq_sequenceresultset.cxx
index 5730ebfb6b97..2c99fa55aeae 100644
--- a/connectivity/source/drivers/postgresql/pq_sequenceresultset.cxx
+++ b/connectivity/source/drivers/postgresql/pq_sequenceresultset.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; eval:(c-set-style "bsd"); tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* This library is free software; you can redistribute it and/or
@@ -17,6 +18,7 @@
* The Initial Developer of the Original Code is: Joerg Budischewski
*
* Copyright: 2000 by Sun Microsystems, Inc.
+ * 2011 by Lionel Elie Mamane <lionel@mamane.lu>
*
* All Rights Reserved.
*
@@ -90,7 +92,10 @@ Reference< XResultSetMetaData > SAL_CALL SequenceResultSet::getMetaData( )
// Oh no, not again
throw ::com::sun::star::sdbc::SQLException(
ASCII_STR( "pq_sequenceresultset: no meta supported " ), *this,
- OUString(), 1, Any() );
+ // I did not find "IM001" in a specific standard,
+ // but it seems to be used by other systems (such as ODBC)
+ // and some parts of LibreOffice special-case it.
+ OUString( ASCII_STR("IM001") ), 1, Any() );
}
return m_meta;
}