Today is the day for questions.
Given:
mysql> show columns from foobar;
+------------+----------+------+-----+---------------------+-------+
| Field | Type | Null | Key | Default | Extra |
+------------+----------+------+-----+---------------------+-------+
| login | char(40) | | MUL | | |
| start_time | datetime | | MUL | 0000-00-00 00:00:00 | |
| stop_time | datetime | | MUL | 0000-00-00 00:00:00 | |
+------------+----------+------+-----+---------------------+-------+
3 rows in set (0.01 sec)
Is there any way to make month() function go faster? For example:
select login, start_time from foobar where login='ctrown' and month(start_time)=7;
shows no index when I use EXPLAIN. For that matter, does MySQL make use
of indexs on datetime types?
Chris...
--
PGP fingerprint: 063FCE320681C336 78C164FC9B2F91EA