dbaccess/source/sdbtools/connection/objectnames.cxx |    4 ++++
 1 file changed, 4 insertions(+)

New commits:
commit e8a1cd6600486d379d045bae450961a83371a052
Author: Lionel Elie Mamane <lio...@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 <fridr...@documentfoundation.org>
    Tested-by: Fridrich Strba <fridr...@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;
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to