RE: more date problems

2001-03-01 Thread Quentin Bennett

Hi,

Can you try "where signup_date  '2001-02-28 23:59:59'", and see what that
gives.

Also, what version are you on - I have had some date problems where the end
of one month and the begining of another get confused (usually when doing a
UNIX_TIMESTAMP).

Maybe then use mysqlbug to report the issue, and include the results of your
tests.

Not much help, I know, but the more information you post, the more help we
can be.

Regards

-Original Message-
From: Daren Cotter [mailto:[EMAIL PROTECTED]]
Sent: Friday, 2 March 2001 1:03 p.m.
To: [EMAIL PROTECTED]
Subject: more date problems


okay, this is a follow-up to my past email...

since I KNOW more than 122 people have signed up today, I did the following
query:

SELECT signup_date, member_id FROM members ORDER BY member_id DESC limit
200;

there are at LEAST 200 people that have signed up today. however, when i do:

SELECT count(*) FROM members WHERE signup_date = now();

I only get 122 results! And YES, I have tried "2001-03-01" instead of
"now()". I ran ISAMCHK with the extended flag, and got no errors whatsoever.
Does anyone have any idea what could be going on? I run this query quite
often, is it possible the result is somehow being saved in a buffer? Should
I shutdown the mysql server and restart it?


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail
[EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

The information contained in this email is privileged and confidential
and intended for the addressee only. If you are not the intended 
recipient, you are asked to respect that confidentiality and not 
disclose, copy or make use of its contents. If received in error 
you are asked to destroy this email and contact the sender immediately. 
Your assistance is appreciated.

-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




RE: more date problems

2001-03-01 Thread Daren Cotter

Quentin,

that does not work either, I still get the 125 number, when there are
actually 500 records  =(

I am using version 3.22.32



-Original Message-
From: Quentin Bennett [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 01, 2001 4:18 PM
To: 'Daren Cotter'; [EMAIL PROTECTED]
Subject: RE: more date problems


Hi,

Can you try "where signup_date  '2001-02-28 23:59:59'", and see what that
gives.

Also, what version are you on - I have had some date problems where the end
of one month and the begining of another get confused (usually when doing a
UNIX_TIMESTAMP).

Maybe then use mysqlbug to report the issue, and include the results of your
tests.

Not much help, I know, but the more information you post, the more help we
can be.

Regards

-Original Message-
From: Daren Cotter [mailto:[EMAIL PROTECTED]]
Sent: Friday, 2 March 2001 1:03 p.m.
To: [EMAIL PROTECTED]
Subject: more date problems


okay, this is a follow-up to my past email...

since I KNOW more than 122 people have signed up today, I did the following
query:

SELECT signup_date, member_id FROM members ORDER BY member_id DESC limit
200;

there are at LEAST 200 people that have signed up today. however, when i do:

SELECT count(*) FROM members WHERE signup_date = now();

I only get 122 results! And YES, I have tried "2001-03-01" instead of
"now()". I ran ISAMCHK with the extended flag, and got no errors whatsoever.
Does anyone have any idea what could be going on? I run this query quite
often, is it possible the result is somehow being saved in a buffer? Should
I shutdown the mysql server and restart it?


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail
[EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

The information contained in this email is privileged and confidential
and intended for the addressee only. If you are not the intended
recipient, you are asked to respect that confidentiality and not
disclose, copy or make use of its contents. If received in error
you are asked to destroy this email and contact the sender immediately.
Your assistance is appreciated.


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




RE: more date problems

2001-03-01 Thread Quentin Bennett

Can you post some of the data - e.g the first 500 rows of the 'order by'
select, and the results of the select with signup_date='2001-03-01'.

Also, how about

Select now(), signup_date from , to see what things are being compared.

Regards

Quentin



-Original Message-
From: Daren Cotter [mailto:[EMAIL PROTECTED]]
Sent: Friday, 2 March 2001 3:34 p.m.
To: Quentin Bennett; 'Daren Cotter'; [EMAIL PROTECTED]
Subject: RE: more date problems


Quentin,

that does not work either, I still get the 125 number, when there are
actually 500 records  =(

I am using version 3.22.32



-Original Message-
From: Quentin Bennett [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 01, 2001 4:18 PM
To: 'Daren Cotter'; [EMAIL PROTECTED]
Subject: RE: more date problems


Hi,

Can you try "where signup_date  '2001-02-28 23:59:59'", and see what that
gives.

Also, what version are you on - I have had some date problems where the end
of one month and the begining of another get confused (usually when doing a
UNIX_TIMESTAMP).

Maybe then use mysqlbug to report the issue, and include the results of your
tests.

Not much help, I know, but the more information you post, the more help we
can be.

Regards

-Original Message-
From: Daren Cotter [mailto:[EMAIL PROTECTED]]
Sent: Friday, 2 March 2001 1:03 p.m.
To: [EMAIL PROTECTED]
Subject: more date problems


okay, this is a follow-up to my past email...

since I KNOW more than 122 people have signed up today, I did the following
query:

SELECT signup_date, member_id FROM members ORDER BY member_id DESC limit
200;

there are at LEAST 200 people that have signed up today. however, when i do:

SELECT count(*) FROM members WHERE signup_date = now();

I only get 122 results! And YES, I have tried "2001-03-01" instead of
"now()". I ran ISAMCHK with the extended flag, and got no errors whatsoever.
Does anyone have any idea what could be going on? I run this query quite
often, is it possible the result is somehow being saved in a buffer? Should
I shutdown the mysql server and restart it?


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail
[EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

The information contained in this email is privileged and confidential
and intended for the addressee only. If you are not the intended
recipient, you are asked to respect that confidentiality and not
disclose, copy or make use of its contents. If received in error
you are asked to destroy this email and contact the sender immediately.
Your assistance is appreciated.

The information contained in this email is privileged and confidential
and intended for the addressee only. If you are not the intended 
recipient, you are asked to respect that confidentiality and not 
disclose, copy or make use of its contents. If received in error 
you are asked to destroy this email and contact the sender immediately. 
Your assistance is appreciated.

-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




RE: more date problems

2001-03-01 Thread Daren Cotter

Ok, here goes...

mysql select member_id, signup_date from members order by member_id desc
limit 410;
+---+-+
| member_id | signup_date |
+---+-+
(here's the last 20 or so rows)
|   0120472 | 2001-03-01  |
|   0120471 | 2001-03-01  |
|   0120470 | 2001-03-01  |
|   0120469 | 2001-03-01  |
|   0120468 | 2001-03-01  |
|   0120467 | 2001-03-01  |
|   0120466 | 2001-03-01  |
|   0120465 | 2001-02-28  |
|   0120464 | 2001-02-28  |
|   0120463 | 2001-02-28  |
|   0120462 | 2001-02-28  |
|   0120461 | 2001-02-28  |
|   0120460 | 2001-02-28  |
|   0120459 | 2001-02-28  |
|   0120458 | 2001-02-28  |
+---+-+

This tells me that there are about 400 people that have signed up TODAY. The
date is correct on the server:

mysql select now();
+-+
| now()   |
+-+
| 2001-03-01 19:33:05 |
+-+

So, the question is, why does this not return 400, like it should???

OK, weird! Now I am getting this error...

mysql select count(*) from members where signup_date = '2001-03-01';
ERROR 1032: Can't find record in 'members'

I have checked the tables using the checking utility, they show up fine.
What's going on?  =)


-Original Message-
From: Quentin Bennett [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 01, 2001 4:45 PM
To: 'Daren Cotter'; [EMAIL PROTECTED]
Subject: RE: more date problems


Can you post some of the data - e.g the first 500 rows of the 'order by'
select, and the results of the select with signup_date='2001-03-01'.

Also, how about

Select now(), signup_date from , to see what things are being compared.

Regards

Quentin



-Original Message-
From: Daren Cotter [mailto:[EMAIL PROTECTED]]
Sent: Friday, 2 March 2001 3:34 p.m.
To: Quentin Bennett; 'Daren Cotter'; [EMAIL PROTECTED]
Subject: RE: more date problems


Quentin,

that does not work either, I still get the 125 number, when there are
actually 500 records  =(

I am using version 3.22.32



-Original Message-
From: Quentin Bennett [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 01, 2001 4:18 PM
To: 'Daren Cotter'; [EMAIL PROTECTED]
Subject: RE: more date problems


Hi,

Can you try "where signup_date  '2001-02-28 23:59:59'", and see what that
gives.

Also, what version are you on - I have had some date problems where the end
of one month and the begining of another get confused (usually when doing a
UNIX_TIMESTAMP).

Maybe then use mysqlbug to report the issue, and include the results of your
tests.

Not much help, I know, but the more information you post, the more help we
can be.

Regards

-Original Message-
From: Daren Cotter [mailto:[EMAIL PROTECTED]]
Sent: Friday, 2 March 2001 1:03 p.m.
To: [EMAIL PROTECTED]
Subject: more date problems


okay, this is a follow-up to my past email...

since I KNOW more than 122 people have signed up today, I did the following
query:

SELECT signup_date, member_id FROM members ORDER BY member_id DESC limit
200;

there are at LEAST 200 people that have signed up today. however, when i do:

SELECT count(*) FROM members WHERE signup_date = now();

I only get 122 results! And YES, I have tried "2001-03-01" instead of
"now()". I ran ISAMCHK with the extended flag, and got no errors whatsoever.
Does anyone have any idea what could be going on? I run this query quite
often, is it possible the result is somehow being saved in a buffer? Should
I shutdown the mysql server and restart it?


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail
[EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

The information contained in this email is privileged and confidential
and intended for the addressee only. If you are not the intended
recipient, you are asked to respect that confidentiality and not
disclose, copy or make use of its contents. If received in error
you are asked to destroy this email and contact the sender immediately.
Your assistance is appreciated.

The information contained in this email is privileged and confidential
and intended for the addressee only. If you are not the intended
recipient, you are asked to respect that confidentiality and not
disclose, copy or make use of its contents. If received in error
you are asked to destroy this email and contact the sender immediately.
Your assistance is appreciated.


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




RE: more date problems

2001-03-01 Thread Atle Veka

On Thu, 1 Mar 2001, Daren Cotter wrote:

 Ok, here goes...
 
 mysql select member_id, signup_date from members order by member_id desc
 limit 410;
 +---+-+
 | member_id | signup_date |
 +---+-+
 (here's the last 20 or so rows)
 |   0120472 | 2001-03-01  |
 |   0120471 | 2001-03-01  |
 |   0120470 | 2001-03-01  |
 |   0120469 | 2001-03-01  |
 |   0120468 | 2001-03-01  |
 |   0120467 | 2001-03-01  |
 |   0120466 | 2001-03-01  |
 |   0120465 | 2001-02-28  |
 |   0120464 | 2001-02-28  |
 |   0120463 | 2001-02-28  |
 |   0120462 | 2001-02-28  |
 |   0120461 | 2001-02-28  |
 |   0120460 | 2001-02-28  |
 |   0120459 | 2001-02-28  |
 |   0120458 | 2001-02-28  |
 +---+-+


Sorry if I've missed earlier threads about this, but what type is the
signup_date field?

AFAIK, datetime fields should show show the full date (and time) even
though you don't insert it. So it should be '2001-03-01 00:00:00' or
whatever NOW() inserts, if thats what you use :)


Atle


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




Re: more date problems

2001-03-01 Thread MikemickaloBlezien

On Thu, 1 Mar 2001 19:32:54 -0800, "Daren Cotter" [EMAIL PROTECTED]
wrote:

So, the question is, why does this not return 400, like it should???

OK, weird! Now I am getting this error...

mysql select count(*) from members where signup_date = '2001-03-01';
ERROR 1032: Can't find record in 'members'

have you tried

mysql select count(*) from members where signup_date = CURDATE();

assuming the signup_date is in the -MM-DD format.



Mike(mickalo)Blezien

Thunder Rain Internet Publishing
Providing Internet Solutions that work!
http://www.thunder-rain.com
Tel: 1(225) 686-2002
=















-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




RE: more date problems

2001-03-01 Thread Quentin Bennett

mysql select count(*) from members where signup_date = '2001-03-01';
ERROR 1032: Can't find record in 'members'

Indicates a problem with the table structure; the result would be 

+--+
| count(*) |
+--+
|0 |
+--+

If there was a problem with the data.

I suggest reviewing the isamchk results, and I'll leave it to the MySQL guys
to interpret the error further.

Good Luck

Quentin


-Original Message-
From: Daren Cotter [mailto:[EMAIL PROTECTED]]
Sent: Friday, 2 March 2001 4:33 p.m.
To: Quentin Bennett; 'Daren Cotter'; [EMAIL PROTECTED]
Subject: RE: more date problems


Ok, here goes...

mysql select member_id, signup_date from members order by member_id desc
limit 410;
+---+-+
| member_id | signup_date |
+---+-+
(here's the last 20 or so rows)
|   0120472 | 2001-03-01  |
|   0120471 | 2001-03-01  |
|   0120470 | 2001-03-01  |
|   0120469 | 2001-03-01  |
|   0120468 | 2001-03-01  |
|   0120467 | 2001-03-01  |
|   0120466 | 2001-03-01  |
|   0120465 | 2001-02-28  |
|   0120464 | 2001-02-28  |
|   0120463 | 2001-02-28  |
|   0120462 | 2001-02-28  |
|   0120461 | 2001-02-28  |
|   0120460 | 2001-02-28  |
|   0120459 | 2001-02-28  |
|   0120458 | 2001-02-28  |
+---+-+

This tells me that there are about 400 people that have signed up TODAY. The
date is correct on the server:

mysql select now();
+-+
| now()   |
+-+
| 2001-03-01 19:33:05 |
+-+

So, the question is, why does this not return 400, like it should???

OK, weird! Now I am getting this error...

mysql select count(*) from members where signup_date = '2001-03-01';
ERROR 1032: Can't find record in 'members'

I have checked the tables using the checking utility, they show up fine.
What's going on?  =)


-Original Message-
From: Quentin Bennett [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 01, 2001 4:45 PM
To: 'Daren Cotter'; [EMAIL PROTECTED]
Subject: RE: more date problems


Can you post some of the data - e.g the first 500 rows of the 'order by'
select, and the results of the select with signup_date='2001-03-01'.

Also, how about

Select now(), signup_date from , to see what things are being compared.

Regards

Quentin



-Original Message-
From: Daren Cotter [mailto:[EMAIL PROTECTED]]
Sent: Friday, 2 March 2001 3:34 p.m.
To: Quentin Bennett; 'Daren Cotter'; [EMAIL PROTECTED]
Subject: RE: more date problems


Quentin,

that does not work either, I still get the 125 number, when there are
actually 500 records  =(

I am using version 3.22.32



-Original Message-
From: Quentin Bennett [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 01, 2001 4:18 PM
To: 'Daren Cotter'; [EMAIL PROTECTED]
Subject: RE: more date problems


Hi,

Can you try "where signup_date  '2001-02-28 23:59:59'", and see what that
gives.

Also, what version are you on - I have had some date problems where the end
of one month and the begining of another get confused (usually when doing a
UNIX_TIMESTAMP).

Maybe then use mysqlbug to report the issue, and include the results of your
tests.

Not much help, I know, but the more information you post, the more help we
can be.

Regards

-Original Message-
From: Daren Cotter [mailto:[EMAIL PROTECTED]]
Sent: Friday, 2 March 2001 1:03 p.m.
To: [EMAIL PROTECTED]
Subject: more date problems


okay, this is a follow-up to my past email...

since I KNOW more than 122 people have signed up today, I did the following
query:

SELECT signup_date, member_id FROM members ORDER BY member_id DESC limit
200;

there are at LEAST 200 people that have signed up today. however, when i do:

SELECT count(*) FROM members WHERE signup_date = now();

I only get 122 results! And YES, I have tried "2001-03-01" instead of
"now()". I ran ISAMCHK with the extended flag, and got no errors whatsoever.
Does anyone have any idea what could be going on? I run this query quite
often, is it possible the result is somehow being saved in a buffer? Should
I shutdown the mysql server and restart it?


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail
[EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

The information contained in this email is privileged and confidential
and intended for the addressee only. If you are not the intended
recipient, you are asked to respect that confidentiality and not
disclose, copy or make use of its contents. If received in error
you are asked to destroy this email and contact the sender immediately.
Your assistance is appreciated.

The information contained in this email is privileged and confidential
and intended for the addressee only. If you are n

RE: more date problems

2001-03-01 Thread Oson, Chris M.

Why can't you do something along the lines of:

select count(*) from pollResults where dayofyear(now()) =
dayofyear(dateEntered) and year(dateEntered) = 2001;

-Original Message-
From: Atle Veka [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 01, 2001 5:51 PM
To: Daren Cotter
Cc: Quentin Bennett; [EMAIL PROTECTED]
Subject: RE: more date problems


On Thu, 1 Mar 2001, Daren Cotter wrote:

 Ok, here goes...
 
 mysql select member_id, signup_date from members order by member_id desc
 limit 410;
 +---+-+
 | member_id | signup_date |
 +---+-+
 (here's the last 20 or so rows)
 |   0120472 | 2001-03-01  |
 |   0120471 | 2001-03-01  |
 |   0120470 | 2001-03-01  |
 |   0120469 | 2001-03-01  |
 |   0120468 | 2001-03-01  |
 |   0120467 | 2001-03-01  |
 |   0120466 | 2001-03-01  |
 |   0120465 | 2001-02-28  |
 |   0120464 | 2001-02-28  |
 |   0120463 | 2001-02-28  |
 |   0120462 | 2001-02-28  |
 |   0120461 | 2001-02-28  |
 |   0120460 | 2001-02-28  |
 |   0120459 | 2001-02-28  |
 |   0120458 | 2001-02-28  |
 +---+-+


Sorry if I've missed earlier threads about this, but what type is the
signup_date field?

AFAIK, datetime fields should show show the full date (and time) even
though you don't insert it. So it should be '2001-03-01 00:00:00' or
whatever NOW() inserts, if thats what you use :)


Atle


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail
[EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php