in reply to Re^2: MySQL datetime
in thread MySQL datetime
Does it, though? So long as one is only concerned about whole days of difference (as appears to be the case for the OP) that fact that one of the stamps has a time doesn't matter.
But if you want to be able to compare for fractional days then Line 17 should be amended to read
my $dayssince = (localtime()->truncate(to => 'day') - $tp) / ONE_DAY;
🦛
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^4: MySQL datetime
by ikegami (Patriarch) on Jul 01, 2025 at 21:55 UTC |