EMAIL REMOVED wrote:
> PHP Version 4.3.10
> MySQL: 4.1.10a
>
> Let's say I have a table "Delivery" with a column 'Date'.
> I had delivery's on 2007-05-01, 2007-05-02, 2007-05-08, 2007-05-15,
> 2007-05-16, 2007-05-17, 2007-05-30
>
> How can I get all deliveries which:
> differ 1 day from each other and where there are 3 connected
> deliveries.
>
> In this example it would result in
> 2007-05-15, 2007-05-16, 2007-05-17
>
J.O.Aho just answered this question:
One of the following should do what you need:
PERIOD_ADD(P,N)
ADDDATE(date,INTERVAL expr unit)
ADDDATE(expr,days)
http://dev.mysql.com/doc/refman/5.0/...ion_period-add
use one of these in your predicate.
--
lark --
EMAIL REMOVED
To reply to me directly, delete "despam".