, November 21, 2002 9:20 PM
Subject: Re: DATETIME Masking and Comparison
--- Keith C. Ivey [EMAIL PROTECTED] wrote:
On 21 Nov 2002, at 15:18, Hans Zaunere wrote:
Because it seems ineffncient to me, as MySQL must be doing more work
to
calculate the range. Even EXPLAIN tells me this, by showing
On 21 Nov 2002, at 18:20, Hans Zaunere wrote:
but as long as it's a DATETIME
column then you are looking for a range of values, so 'range' is the
best you're going to get in the EXPLAIN output.
Yes, but the real data I'm looking for is not a range - it's simply a part of
a single
sql,query
At 8:53 -0500 11/22/02, Nicholas Elliott wrote:
So essentially, you want to put an index on part of the column, and not the
whole column, right? As in, an index on just the date part, and not the time
part. (Or both -- it seems like you want it to do both at the same time).
Much like
--- Keith C. Ivey [EMAIL PROTECTED] wrote:
On 21 Nov 2002, at 18:20, Hans Zaunere wrote:
but as long as it's a DATETIME
column then you are looking for a range of values, so 'range' is the
best you're going to get in the EXPLAIN output.
Yes, but the real data I'm looking for is
On 22 Nov 2002, at 12:43, Hans Zaunere wrote:
I know all about cacheing and all, but I'm just frustrated
by this DATETIME column issue, after switching from the fantastic INT column
and UNIX timestamp scheme.
If using a Unix timestamp was fantastic, why did you move away from
it? (And
I have a DATETIME column, indexed, which I store both a date and time in, as
expected. However, I often want to select all rows for a given date,
regardless of time.
I've played around with a couple different methods, but the only way I can
see to use the INDEX (according to EXPLAIN) is doing a
On 21 Nov 2002, at 14:38, Hans Zaunere wrote:
I've played around with a couple different methods, but the only way I can
see to use the INDEX (according to EXPLAIN) is doing a query along the
lines of:
... WHERE thecolumn BETWEEN '2002-11-17' AND '2002-11-18'
You don't explain what you
On 21 Nov 2002, at 15:18, Hans Zaunere wrote:
Because it seems ineffncient to me, as MySQL must be doing more work to
calculate the range. Even EXPLAIN tells me this, by showing that a
less-than-optimal TYPE is being used. Although WHERE thecolumn =
'2002-11-17' doesn't yield any results,
--- Keith C. Ivey [EMAIL PROTECTED] wrote:
On 21 Nov 2002, at 14:38, Hans Zaunere wrote:
I've played around with a couple different methods, but the only way I
can
see to use the INDEX (according to EXPLAIN) is doing a query along the
lines of:
... WHERE thecolumn BETWEEN
--- Keith C. Ivey [EMAIL PROTECTED] wrote:
On 21 Nov 2002, at 15:18, Hans Zaunere wrote:
Because it seems ineffncient to me, as MySQL must be doing more work to
calculate the range. Even EXPLAIN tells me this, by showing that a
less-than-optimal TYPE is being used. Although WHERE
10 matches
Mail list logo