[Libreoffice-commits] core.git: Branch 'libreoffice-4-1' - dbaccess/source
Lionel Elie Mamane
lionel at mamane.lu
Thu Jul 4 05:39:17 PDT 2013
dbaccess/source/sdbtools/connection/objectnames.cxx | 4 ++++
1 file changed, 4 insertions(+)
New commits:
commit e8a1cd6600486d379d045bae450961a83371a052
Author: Lionel Elie Mamane <lionel at mamane.lu>
Date: Wed Jul 3 18:10:38 2013 +0200
database suggestname: no '/' for queries
In particular, this keeps the new query wizard
from silently failing by default
when the underlying table name has a slash: it would
generate a name proposal based on the table name,
and then use suggestName to get a similar,
yet guaranteed allowed name.
In this case, the "guaranteed allowed" part was failing,
since suggestName failed to strip slashes, which are
forbidden in query names.
Change-Id: I53d3976979ee45f5659765ed5dd3371b78837b5b
Reviewed-on: https://gerrit.libreoffice.org/4709
Reviewed-by: Fridrich Strba <fridrich at documentfoundation.org>
Tested-by: Fridrich Strba <fridrich at documentfoundation.org>
diff --git a/dbaccess/source/sdbtools/connection/objectnames.cxx b/dbaccess/source/sdbtools/connection/objectnames.cxx
index 9e1d0dd..add3509 100644
--- a/dbaccess/source/sdbtools/connection/objectnames.cxx
+++ b/dbaccess/source/sdbtools/connection/objectnames.cxx
@@ -419,6 +419,10 @@ namespace sdbtools
else
sBaseName = OUString( SdbtRes( STR_BASENAME_QUERY ) );
}
+ else if( _CommandType == CommandType::QUERY )
+ {
+ sBaseName=sBaseName.replace('/', '_');
+ }
OUString sName( sBaseName );
sal_Int32 i = 1;
More information about the Libreoffice-commits
mailing list