From 499738f7d9bafd7699e4f6269e5968c504292174 Mon Sep 17 00:00:00 2001 From: Alexkurd <7689609+Alexkurd@users.noreply.github.com> Date: Tue, 13 Apr 2021 12:18:24 +0300 Subject: [PATCH] Incorrect DATETIME value: '0000-00-00 00:00:00' FIX Query Error 1525: Incorrect DATETIME value: '0000-00-00 00:00:00' --- lib/model/shopOrder.model.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/model/shopOrder.model.php b/lib/model/shopOrder.model.php index 10020b1d6..26837ad3e 100644 --- a/lib/model/shopOrder.model.php +++ b/lib/model/shopOrder.model.php @@ -778,7 +778,7 @@ public function getMinDate() } $sql = "SELECT MIN(create_datetime) FROM shop_order - WHERE create_datetime > '0000-00-00 00:00:00'"; + WHERE create_datetime > '1970-01-01 00:00:00'"; $result = $this->query($sql)->fetchField(); if ($result) { $cache->set($result);