Gossamer Forum
Home : General : Perl Programming :

Seconds since the epoch, months and number of days

Quote Reply
Seconds since the epoch, months and number of days
Hi,

I was working on a global to extract records from a table which are timestamped. What I would like to do is determine date ranges. Now.. using days this is very easy to do since I can determine current time, and apply the 86400 * days formula to go back in time. However, this does not takes into account months with 30, 31 or 29 days.

What would be the proper way to determine a date range for timestamped records so I can create data ranges taking into consideration the number of days for each month, is there any function for this or do I have to manually celculate the number of days for each month in the past and adjust accordingly?
Subject Author Views Date
Thread Seconds since the epoch, months and number of days jaltuve 4180 Sep 23, 2005, 1:34 PM
Thread Re: [jaltuve] Seconds since the epoch, months and number of days
fuzzy logic 4050 Sep 23, 2005, 9:12 PM
Post Re: [fuzzy logic] Seconds since the epoch, months and number of days
jaltuve 4055 Sep 23, 2005, 10:53 PM