Jim Winstead wrote:

On Wed, Nov 09, 2005 at 02:06:59PM +1100, Daniel Kasak wrote:
Background on data:

mysql> select ID, Loc_FK, BatchNo, EAPDate from EAPosting where Loc_FK=7249;
+-------+--------+---------+------------+
| ID    | Loc_FK | BatchNo | EAPDate    |
+-------+--------+---------+------------+
| 59370 |   7249 |   60992 | 2004-08-31 |
| 60512 |   7249 |   64986 | 2004-09-30 |
| 60513 |   7249 |   64986 | 2004-10-31 |
| 60514 |   7249 |   64986 | 2004-11-30 |
| 60515 |   7249 |   64986 | 2004-12-31 |
| 61714 |   7249 |   70753 | 2005-01-31 |
| 61715 |   7249 |   70753 | 2005-02-28 |
| 61716 |   7249 |   70753 | 2005-03-31 |
| 63124 |   7249 |   74142 | 2005-04-30 |
| 63125 |   7249 |   74142 | 2005-05-31 |
| 63126 |   7249 |   74142 | 2005-06-30 |
| 64194 |   7249 |   83404 | 2005-08-31 |
| 64195 |   7249 |   83404 | 2005-09-30 |
+-------+--------+---------+------------+
13 rows in set (0.01 sec)

So far so good.

mysql> select max(EAPDate) from EAPosting where Loc_FK=7249;
+--------------+
| max(EAPDate) |
+--------------+
| 2005-09-30   |
+--------------+
1 row in set (0.00 sec)

*BIG* problem! What's up with the 2005-09-30 record?

Perhaps I'm missing something, but 2005-09-30 looks like the maximum
value of EAPDate in the data above. What did you expect the result to
be?

Jim Winstead
MySQL Inc.
Um. Yeah. Fair enough. From Perl, I was getting 2005-08-31, and I *swear* I tried it from the console and got the same thing, but maybe I didn't. I tried it a couple of times before posting. Weird.

Now I've just tried it from Perl again and I get the right ( 2005-09-30 ) answer. It wasn't like that a second ago, honest!

I will investigate further. I've got full query logs :)

--
Daniel Kasak
IT Developer
NUS Consulting Group
Level 5, 77 Pacific Highway
North Sydney, NSW, Australia 2060
T: (+61) 2 9922-7676 / F: (+61) 2 9922 7989
email: [EMAIL PROTECTED]
website: http://www.nusconsulting.com.au

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to