RE: [PHP] mysql question
| From: | John Holmes | Date: | Fri, 12 Jul 2002 02:12:54 +0000 |
| Subject: | RE: [PHP] mysql question | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-107288@lists.php.net to get a copy of this message | ||
> Привет!
Gesundheit
> 1LT John W. Holmes wrote:
> > How about
> >
> > SELECT * FROM table WHERE $current_shot BETWEEN start_shot AND
end_shot
>
> *if* that was on Oracle *and* the table was big you'd notice that your
> performance goes down. Don't ask me why. And I never checked it on
> MySql. But watch out for betweens. Check them.
Yes, good point. I don't know if it matters in MySQL either, but always
test your queries and see which is faster. EXPLAIN may come in handy
here. I don't see why it would be different, it seems like both would be
interpreted the same...
---John Holmes...