From c431a28fe81f5088a3dcb98d1f30d90cc595cfce Mon Sep 17 00:00:00 2001 From: taolx0 Date: Tue, 12 Mar 2024 10:57:30 +0800 Subject: [PATCH] chore:maximize decimal value --- sqle/model/audit_plan.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sqle/model/audit_plan.go b/sqle/model/audit_plan.go index d80c7920f5..d374228a04 100644 --- a/sqle/model/audit_plan.go +++ b/sqle/model/audit_plan.go @@ -258,7 +258,7 @@ func (s *Storage) UpdateSlowLogAuditPlanSQLs(auditPlanId uint, sqls []*AuditPlan COALESCE(JSON_EXTRACT(info, '$.counter'), 0) +COALESCE(JSON_EXTRACT(values(info), '$.counter'), 1) ) - AS DECIMAL(12,6) + AS DECIMAL(65,6) ), '$.first_query_at', IF( JSON_TYPE(JSON_EXTRACT(info, '$.first_query_at'))="NULL", @@ -308,7 +308,7 @@ ON DUPLICATE KEY UPDATE sql_content = VALUES(sql_content), COALESCE(JSON_EXTRACT(info, '$.counter'), 0) + COALESCE(JSON_EXTRACT(VALUES(info), '$.counter'), 1) ) - AS DECIMAL(12, 6)), + AS DECIMAL(65,6)), '$.start_time', JSON_EXTRACT(values(info), '$.start_time'));`