Feb 4, 2005 #1 mirfan Programmer Feb 4, 2005 13 PK hello i need little help.... i want to calculate difference in days between two dates.. like one date is 31-01-2005 other is 05-02-2005... the difference should be 5... Thanks
hello i need little help.... i want to calculate difference in days between two dates.. like one date is 31-01-2005 other is 05-02-2005... the difference should be 5... Thanks
Feb 4, 2005 #2 Bastien Programmer May 29, 2000 1,683 CA If the dates are stored in a db, you can use sql to do the calc for you. Check the docs for the correct way to do this. Or with php, convert the dates to unix timestamps subtract and divide the total by the number of seconds in a day (60*60*24). Bastien I wish my computer would do what I want it to do, instead of what I tell it to do... Upvote 0 Downvote
If the dates are stored in a db, you can use sql to do the calc for you. Check the docs for the correct way to do this. Or with php, convert the dates to unix timestamps subtract and divide the total by the number of seconds in a day (60*60*24). Bastien I wish my computer would do what I want it to do, instead of what I tell it to do...
Feb 4, 2005 #3 DRJ478 IS-IT--Management Aug 10, 2001 2,264 US There is a FAQ on this very topic: faq434-3493 Upvote 0 Downvote