You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cayenne.apache.org by "Andrus Adamchik (Jira)" <ji...@apache.org> on 2019/11/20 07:50:00 UTC

[jira] [Created] (CAY-2639) DBImport and DB name case sensitivity

Andrus Adamchik created CAY-2639:
------------------------------------

             Summary: DBImport and DB name case sensitivity
                 Key: CAY-2639
                 URL: https://issues.apache.org/jira/browse/CAY-2639
             Project: Cayenne
          Issue Type: Improvement
    Affects Versions: 4.1.RC2
         Environment: MySQL 5.7
            Reporter: Andrus Adamchik


I just ran into a minor issue with DB import Modeler process. 

Given: A table with lowercase table name and uppercase column names 

1. DB Import the table to Cayenne. Import preserves correct capitalization. 
2. Due to a change in project naming conventions, column name capitalization was changed to lowercase.
3. Rerun DB import.. Result: no changes were reported, and I had to adjust the model by hand.

So DB Import is CS for new names, but is CI when checking for changes. 

The topic of case sensitivity of DB names is not a simple one. There are lots of variations and bad legacy.

So perhaps we need to explicitly detect the case when a CI check matches a db object (a table or a column), but CS reports a pair of events - object deletion and another object creation and present a dialog for the user to decide what to do (1. replace the original names, 2. process as delete/create) ... Not sure if we care to preserve the current behavior (i.e. "3. Do nothing - preserve the original capitalization")?

In any event, this issues has a minor impact, as people usually don't randomly change name capitalization. 





--
This message was sent by Atlassian Jira
(v8.3.4#803005)