MySQL lowercases schema name in `database()` and `show databases` after `use <MixedCase>`
- Dominant language
- Go
- Stars
- 24.4k
- Forks
- 873
- Avg merge
- 1d 8h
- Merged PRs (30d)
- 120
Description
Creating and selecting a mixed-case schema is reflected as lowercase in MySQL, but Dolt returns the requested name.
## Dolt
```sql
# Welcome to the DoltSQL shell.
# Statements must be terminated with ';'.
# "exit" or "quit" (or Ctrl-D) to exit. "\help" for help.
10382/main> create schema Test;
Query OK, 1 row affected (0.02 sec)
10382/main> use Test;
Database Changed
Test/main> select database();
+------------+
| database() |
+------------+
| Test |
+------------+
1 row in set (0.00 sec)
```
## MySQL
```sql
mysql> drop schema Test;
Query OK, 0 rows affected (0.101 sec)
mysql> create schema Test;
Query OK, 1 row affected (0.063 sec)
mysql> use Test;
Database changed
mysql> select database();
+------------+
| database() |
+------------+
| test |
+------------+
1 row in set (0.004 sec)
```
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by reproducing the CREATE SCHEMA, USE, SELECT DATABASE(), and SHOW DATABASES statements in the DoltSQL shell, then compare the results with MySQL for a mixed-case schema. Done means Dolt consistently matches MySQL's lowercasing behavior for the selected schema and database listing.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- mysql, sql
- Domain
- databases
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 58/100