Re: Why doesn't MySQL cache queries that start with parenthesis? (further info)

2005-03-29 Thread Sergei Golubchik
Hi! On Mar 28, Homam S.A. wrote: It seems that MySQL freaks out whenever it seems something that looks like a derive table and refuses it to cache. Even a non-UNION query like: SELECT * FROM (SELECT * FROM X WHERE A = 5) AS DerivedTable Won't be cached. It's a bug. Could you submit a

Why doesn't MySQL cache queries that start with parenthesis?

2005-03-28 Thread Homam S.A.
I have a query of the form: (SELECT A, B from X ORDER BY A LIMIT 1000) UNION ALL (SELECT A, B from Y ORDER BY A LIMIT 1000) ORDER BY A I thought may be each query needs to start with SELECT, so I wrapped the above query in a derived-table expression like: SELECT * FROM ( (SELECT A, B from X

Why doesn't MySQL cache queries that start with parenthesis? (further info)

2005-03-28 Thread Homam S.A.
It seems that MySQL freaks out whenever it seems something that looks like a derive table and refuses it to cache. Even a non-UNION query like: SELECT * FROM (SELECT * FROM X WHERE A = 5) AS DerivedTable Won't be cached. I read a comment in the documentation that if you put SQL_CACHE in the