Results 1 to 2 of 2

Thread: date calculations

  1. #1
    Join Date
    Feb 2004
    Posts
    2

    date calculations

    i want to get the records of people whose birth days are in the next 10 days.

  2. #2
    Join Date
    Jan 2004
    Location
    Cincinnati, OH
    Posts
    30
    select * from YourTable
    where
    (unix_timestamp(date_format($dob,"2004-%m-%d 00:00:00")))
    between (unix_timestamp(date_format(curdate(),"2004-%m-%d 00:00:00")))
    and (unix_timestamp(date_format((curdate()+interval 10 day),"2004-%m-%d 00:00:00")))

    $dob is the date of birth.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •