photo-stats

Unnamed repository; edit this file 'description' to name the repository.
git clone git://code.clttr.info/photo-stats.git
Log | Files | Refs | README | LICENSE

commit dfa50ac7e8a32a33f67e329c8fdb4651d001aa80
parent 01652fad26b362e043a3e6495a150658c26422b8
Author: René Wagner <rwagner@rw-net.de>
Date:   Sun, 16 Aug 2020 17:12:38 +0200

fix warnings on unvalid date

Diffstat:
Mphosta.pl | 8++++----
1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/phosta.pl b/phosta.pl @@ -154,22 +154,22 @@ sub get_sql { when ('month') { - $fieldlist = "strftime('%Y/%m', datetimeoriginal) as month,"; + $fieldlist = "IFNULL(strftime('%Y/%m', datetimeoriginal), '-') as month,"; $grouplist = "strftime('%Y/%m', datetimeoriginal)"; } when ('week') { - $fieldlist = "strftime('%Y/%W', datetimeoriginal) as week_of_year,"; + $fieldlist = "IFNULL(strftime('%Y/%W', datetimeoriginal), '-') as week_of_year,"; $grouplist = "strftime('%Y/%W', datetimeoriginal)"; } when ('year') { - $fieldlist = "strftime('%Y', datetimeoriginal) as year,"; + $fieldlist = "IFNULL(strftime('%Y', datetimeoriginal), '-') as year,"; $grouplist = "strftime('%Y', datetimeoriginal)"; } when ('hour') { - $fieldlist = "strftime('%H', datetimeoriginal) as hour,"; + $fieldlist = "IFNULL(strftime('%H', datetimeoriginal), '-') as hour,"; $grouplist = "strftime('%H', datetimeoriginal)"; } }