[MDEV-14137] Renaming temporary to an part-uppercase named table fails on a MacOS case-insensitive file system Created: 2017-10-26  Updated: 2017-10-27

Status: Confirmed
Project: MariaDB Server
Component/s: Data Definition - Alter Table, Data Definition - Temporary
Affects Version/s: 10.2.9
Fix Version/s: 10.2

Type: Bug Priority: Major
Reporter: Phil Wilkinson Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: None
Environment:

macOS 10.13 High Sierra (64-bit)


Attachments: PNG File image-2017-10-26-11-10-23-900.png     PNG File image-2017-10-26-11-18-30-168.png     File my.cnf    

 Description   

Mac specs:


Processor: Intel Core i5-4690 (4 cores at 3.5GHz)
File System: CoreStorage Logical Volume • Mac OS Extended (Journaled, Encrypted)

Please see attached my.cnf in case that matters.

Steps to reproduce:

# Create the initial temporary table
CREATE TEMPORARY TABLE foo AS (SELECT 1);
 
# Ensure it exists
SELECT * FROM foo;
 
# Alter table ensuring destination name contains an uppercase alphabetic character
ALTER TABLE foo RENAME Bar;
 
# Both tables no longer exist
SELECT * FROM foo;
SELECT * FROM Bar;



 Comments   
Comment by Alice Sherepa [ 2017-10-27 ]

I confirm the problem, os x 10.13, MariaDB 10.2.9, both with Myisam and InnoDB.

MariaDB [test]> CREATE TEMPORARY TABLE foo AS (SELECT 1);
Query OK, 1 row affected (0.05 sec)
Records: 1  Duplicates: 0  Warnings: 0
 
MariaDB [test]> SELECT * FROM foo;
+---+
| 1 |
+---+
| 1 |
+---+
1 row in set (0.00 sec)
 
MariaDB [test]> ALTER TABLE foo RENAME Bar;
Query OK, 0 rows affected (0.00 sec)
 
MariaDB [test]> SELECT * FROM foo;
ERROR 1146 (42S02): Table 'test.foo' doesn't exist
MariaDB [test]> SELECT * FROM Bar;
ERROR 1146 (42S02): Table 'test.bar' doesn't exist

Generated at Thu Feb 08 08:11:12 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.