Why does sqlite3_analyzer upcase table names?
(1) By Jeffrey Friedl (jfriedl) on 2020-12-17 06:35:31 [link] [source]
sqlite3_analyzer prints table names in all upper case, as opposed to the actual (possibly-mixed) case that the names are in the database. Does anyone know why?
Would a command-line option to avoid this be reasonable? I know that sqlite3 itself doesn't care about the letter case, but my eyes much prefer to read ThisIsSomeTable instead of THISISSOMETABLE......
(2) By Gunter Hick (gunter_hick) on 2020-12-17 07:37:13 in reply to 1 [link] [source]
SQL in general and SQLite in particular are case blind. Mixing case in names may be prettier to read, but has no significance.
(3) By Jeffrey Friedl (jfriedl) on 2020-12-18 09:58:39 in reply to 2 [link] [source]
Yes, as I wrote, I understand that SQLite itself doesn't care, but a human reading the output of sqlite3_analyzer almost certainly does. It seems gratuitous for sqlite3_analyzer to upcase the names, but perhaps there's a practical, useful reason?
(4) By Stephan Beal (stephan) on 2020-12-18 10:04:23 in reply to 3 [source]
It seems gratuitous for sqlite3_analyzer to upcase the names, but perhaps there's a practical, useful reason?
If names are internally mixed-case but the internals are case-insensitive then it's slower to compare/search them because each character has to be compared 1-2 times during a comparison. If they're internally normalized to either upper or lower case, comparison speed is improved by ruling out 50% of the possibilities in advance.