<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.kde.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.6"
          urlbase="https://bugs.kde.org/"
          
          maintainer="sysadmin@kde.org"
>

    <bug>
          <bug_id>307479</bug_id>
          
          <creation_ts>2012-09-27 12:25:14 +0000</creation_ts>
          <short_desc>Kexi refuses to delete imported tables</short_desc>
          <delta_ts>2014-02-12 10:29:50 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>2</classification_id>
          <classification>Applications</classification>
          <product>KEXI</product>
          <component>General</component>
          <version>2.5.2</version>
          <rep_platform>openSUSE</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>CLOSED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>NOR</priority>
          <bug_severity>major</bug_severity>
          <target_milestone>2.5</target_milestone>
          
          
          <everconfirmed>0</everconfirmed>
          <reporter name="Guido Schmidt">guido</reporter>
          <assigned_to name="Jarosław Staniek">staniek</assigned_to>
          
          
          <cf_commitlink>http://commits.kde.org/calligra/c8d4eb10b5d8256c74c02a54d313ceb5ce5db671</cf_commitlink>
          <cf_versionfixedin>2.5.3</cf_versionfixedin>
          <cf_sentryurl></cf_sentryurl>
          <votes>0</votes>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1301030</commentid>
    <comment_count>0</comment_count>
    <who name="Guido Schmidt">guido</who>
    <bug_when>2012-09-27 12:25:14 +0000</bug_when>
    <thetext>I imported a couple of simple tables (all empty). It is not possible to delete them. When I try I always get a message &quot;Could not remove object.&quot;

Deleting a table I created using Kexi works.

Reproducible: Always

Steps to Reproduce:
1. Import tables from a distant MySQL-server into another db on the same server.
2. Select a table.
3. Press the delete-button.
4. Confirm the delete-warning.
Actual Results:  
The error-message &quot;Could not remove object.&quot; appears.

Expected Results:  
The table should get deleted. If this is not possible because of any dependencies that have to be removed first (although I think in my case there aren&apos;t any) the message should point to them or - even better - offer to remove them too.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1301156</commentid>
    <comment_count>1</comment_count>
    <who name="Jarosław Staniek">staniek</who>
    <bug_when>2012-09-27 21:12:49 +0000</bug_when>
    <thetext>Thanks for reporting. Could you please attach a sample database having the issue (below)? 
Can be the one with empty table(s).</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1301507</commentid>
    <comment_count>2</comment_count>
      <attachid>74230</attachid>
    <who name="Guido Schmidt">guido</who>
    <bug_when>2012-09-29 13:46:16 +0000</bug_when>
    <thetext>Created attachment 74230
Database with two undeletable tables

The attached kexi-db contains two tables I managed to import (see bug #307575) from the db attached to bug #307571.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1303137</commentid>
    <comment_count>3</comment_count>
    <who name="Jarosław Staniek">staniek</who>
    <bug_when>2012-10-04 22:35:07 +0000</bug_when>
    <thetext>Git commit 6e43601ab185afbbab8d18e78bf73214a17c3e64 by Jaroslaw Staniek.
Committed on 04/10/2012 at 22:13.
Pushed by staniek into branch &apos;calligra/2.5&apos;.

Fix the lowercase fix and db import

KexiDB
*A fix for the lowercase fix: keep table names in original format but compare them in case-insensitive way when needed
**This way importing from databases with tables upper-case characters works

Migration
*Fix invalid SQL generation for database import
*Fix importing from databases with tables upper-case characters
Related: bug 306523
REVIEW:106726

M  +5    -11   kexi/core/kexiproject.cpp
M  +14   -11   kexi/kexidb/connection.cpp
M  +1    -1    kexi/kexidb/expression.cpp
M  +1    -1    kexi/kexidb/tableschema.cpp
M  +26   -24   kexi/migration/keximigrate.cpp
M  +4    -3    kexi/migration/mysql/mysqlmigrate.cpp

http://commits.kde.org/calligra/6e43601ab185afbbab8d18e78bf73214a17c3e64</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1303140</commentid>
    <comment_count>4</comment_count>
    <who name="Jarosław Staniek">staniek</who>
    <bug_when>2012-10-04 22:35:59 +0000</bug_when>
    <thetext>Git commit 420a12d13746f5d5cebd9a10d140fd66b141ab59 by Jaroslaw Staniek.
Committed on 04/10/2012 at 22:13.
Pushed by staniek into branch &apos;master&apos;.

Fix the lowercase fix and db import

KexiDB
*A fix for the lowercase fix: keep table names in original format but compare them in case-insensitive way when needed
**This way importing from databases with tables upper-case characters works

Migration
*Fix invalid SQL generation for database import
*Fix importing from databases with tables upper-case characters
Related: bug 306523

M  +5    -11   kexi/core/kexiproject.cpp
M  +26   -24   kexi/migration/keximigrate.cpp
M  +4    -3    kexi/migration/mysql/mysqlmigrate.cpp
M  +14   -11   libs/db/connection.cpp
M  +1    -1    libs/db/expression.cpp
M  +1    -1    libs/db/tableschema.cpp

http://commits.kde.org/calligra/420a12d13746f5d5cebd9a10d140fd66b141ab59</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1303141</commentid>
    <comment_count>5</comment_count>
    <who name="Jarosław Staniek">staniek</who>
    <bug_when>2012-10-04 22:37:52 +0000</bug_when>
    <thetext>Importing issues have been fixed too by the way.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1303173</commentid>
    <comment_count>6</comment_count>
    <who name="Jarosław Staniek">staniek</who>
    <bug_when>2012-10-04 23:44:49 +0000</bug_when>
    <thetext>Git commit c8d4eb10b5d8256c74c02a54d313ceb5ce5db671 by Jaroslaw Staniek.
Committed on 04/10/2012 at 22:13.
Pushed by staniek into branch &apos;kexi-altertable-staniek&apos;.

Fix the lowercase fix and db import

KexiDB
*A fix for the lowercase fix: keep table names in original format but compare them in case-insensitive way when needed
**This way importing from databases with tables upper-case characters works

Migration
*Fix invalid SQL generation for database import
*Fix importing from databases with tables upper-case characters
Related: bug 306523

M  +5    -11   kexi/core/kexiproject.cpp
M  +26   -24   kexi/migration/keximigrate.cpp
M  +4    -3    kexi/migration/mysql/mysqlmigrate.cpp
M  +11   -8    libs/db/connection.cpp
M  +1    -1    libs/db/expression.cpp
M  +1    -1    libs/db/tableschema.cpp

http://commits.kde.org/calligra/c8d4eb10b5d8256c74c02a54d313ceb5ce5db671</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1410734</commentid>
    <comment_count>7</comment_count>
    <who name="Jarosław Staniek">staniek</who>
    <bug_when>2013-11-11 23:28:55 +0000</bug_when>
    <thetext>Git commit 676b32b8e2f506721ce3b6573f51673b84ba998c by Jaroslaw Staniek.
Committed on 23/10/2013 at 20:20.
Pushed by staniek into branch &apos;master&apos;.

Fix of handling case sensitivity of object names

*A fix for the lowercase fix: keep table names in original format but compare them in case-insensitive way when needed
**This way importing from databases with tables upper-case characters works
Related: bug 306523

from Calligra master 420a12d13746f5d5ce

M  +14   -10   Predicate/Connection.cpp
M  +1    -1    Predicate/TableSchema.cpp
M  +0    -1    Predicate/expression/VariableExpression.cpp

http://commits.kde.org/predicate/676b32b8e2f506721ce3b6573f51673b84ba998c</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="0"
              isprivate="0"
          >
            <attachid>74230</attachid>
            <date>2012-09-29 13:46:16 +0000</date>
            <delta_ts>2012-09-29 13:46:16 +0000</delta_ts>
            <desc>Database with two undeletable tables</desc>
            <filename>auftrag_test_kexi_import.sql.bz2</filename>
            <type>application/x-bzip</type>
            <size>1491</size>
            <attacher name="Guido Schmidt">guido</attacher>
            
              <data encoding="base64">QlpoNDFBWSZTWYu9UjkAAprfgAAQcP//+n/v//D////wYAc/B5aNfQAA+dgAAoeGlT0nqeoNGIDI
DQAAAADIGmjJocZMmjEMTTAQMCaYIwTE000AGEGp6Eo0jIxNNDTJgCYjTIyYQMAAINPUqeUzQRqA
aBoAAAyAAAAAZSQD1A9RoyaAAANNAAAAAAVJICBMIZBNTxT1DU9J6am0nppqYCZpqA006k4DXaS6
rE47I00qpCpUVUpR6ailKqRrP9PO9sTTF1Boi1fh89h1bPhlZVSoleSyI8dkkjUPbVKqm/6Pq4VV
tgyE3VBso/b5Xj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