I have a drupal user table:
+------------------+------------------+------+-----+---------+----------------+
| Field | Type | Null | Key | Default | Extra |
+------------------+------------------+------+-----+---------+----------------+
| uid | int(10) unsigned | NO | PRI | NULL | auto_increment |
| name | varchar(60) | NO | UNI | | |
| pass | varchar(32) | NO | | | |
| mail | varchar(64) | YES | MUL | | |
| mode | tinyint(4) | NO | | 0 | |
| sort | tinyint(4) | YES | | 0 | |
| threshold | tinyint(4) | YES | | 0 | |
| theme | varchar(255) | NO | | | |
| signature | varchar(255) | NO | | | |
| created | int(11) | NO | MUL | 0 | |
| access | int(11) | NO | MUL | 0 | |
| login | int(11) | NO | | 0 | |
| status | tinyint(4) | NO | | 0 | |
| timezone | varchar(8) | YES | | NULL | |
| language | varchar(12) | NO | | | |
| picture | varchar(255) | NO | | | |
| init | varchar(64) | YES | | | |
| data | longtext | YES | | NULL | |
| signature_format | smallint(6) | NO | | 0 | |
+------------------+------------------+------+-----+---------+----------------+
19 rows in set (0.09 sec)
I'm doing a lot of SELECT uid FROM users WHERE name='dave';
Does it make sense to create the new table:
+-------+-------------+------+-----+---------+-------+
| Field | Type | Null | Key | Default | Extra |
+-------+-------------+------+-----+---------+-------+
| uid | int(10) | NO | PRI | NULL | |
| name | varchar(64) | NO | | NULL | |
+-------+-------------+------+-----+---------+-------+
2 rows in set (0.09 sec)
Are there any benefits?