|数据库名称|SQL语句|总执行次数|总执行时间(秒)|最大执行时长|平均执行时间|锁定总时长|最大锁定时长|解析总行数|解析最大行数|返回总行数|返回最大行数|
| - | - | - | - | - | - | - | - | - | - | - | - |
|v4_user|SELECT DATE_FORMAT(es.sales_date,?) AS statistic_date,DATE_FORMAT(es.sales_date,?) AS statistic_month,DATE_FORMAT(es.update_time,?) AS busi_date,es.tenant_id,es.tenant_app_id,ifnull(sp.id,?) AS shop_id,ifnull(emp.id,?) AS employee_id,? AS saleStatus,?*count(t?.id) AS `comment`,?*ifnull(sum(if(t?.average_score<t?.low_score,?,?)),?) AS low_comment,?*ifnull(sum(t?.average_score),?) AS score_total FROM v4_sales.`comment`t? JOIN v4_sales.erp_sales es ON es.id=t?.order_id AND es.tenant_id=t?.tenant_id AND es.tenant_app_id=t?.tenant_app_id AND es.sales_status=? LEFT JOIN tenant.employee emp ON es.tenant_id=emp.tenant_id AND emp.employee_erp_id=es.employee_erp_id LEFT JOIN v4_employee.shop sp ON es.tenant_id=sp.tenant_id AND es.dept_erp_id=sp.dept_id WHERE es.tenant_id=? AND es.tenant_app_id=? AND es.update_time>=? AND es.update_time<? GROUP BY es.tenant_id,es.tenant_app_id,sp.id,emp.id,DATE_FORMAT(es.sales_date,?),DATE_FORMAT(es.sales_date,?),DATE_FORMAT(es.update_time,?) LIMIT ? OFFSET ?|1|1|1||0|0|204367|204367|1|1|
|user_service|SELECT * FROM `wx_user`|1|145|145||0|0|12689245|12689245|12689245|12689245|
|v4_user|SELECT DATE_FORMAT(tt?.recept_time,?) AS statistic_date,DATE_FORMAT(tt?.recept_time,?) AS statistic_month,tt?.tenant_id,tt?.tenant_app_id,tt?.shop_id,tt?.employee_id,tt?.fieldName,tt?.fieldValue,count(*) AS total FROM (SELECT t?.recept_time,t?.tenant_id,t?.tenant_app_id,t?.shop_id,t?.employee_id,? AS fieldName,TRIM(? FROM JSON_EXTRACT(t?.checkin_labels,concat(SUBSTRING(TRIM(? FROM JSON_SEARCH(t?.checkin_labels,?,?)),?,LOCATE(?,TRIM(? FROM JSON_SEARCH(t?.checkin_labels,?,?)))-?),?))) AS fieldValue FROM v4_user.reception_customer t? WHERE t?.tenant_id=? AND t?.tenant_app_id=? AND t?.create_time>=? AND t?.create_time<? AND JSON_CONTAINS(t?.checkin_labels,JSON_OBJECT(?,?)))tt? GROUP BY DATE_FORMAT(tt?.recept_time,?),DATE_FORMAT(tt?.recept_time,?),tt?.tenant_id,tt?.tenant_app_id,tt?.shop_id,tt?.employee_id,tt?.fieldName,tt?.fieldValue|1|1|1||0|0|111611|111611|106|106|
|account|SELECT t.tenant_app_id,t.user_id,t.is_drawed_img FROM customer.tenant_user_image t WHERE t.tenant_app_id=? AND t.update_time>=? AND t.update_time<=? AND t.is_drawed_img=? GROUP BY t.tenant_app_id,t.user_id,t.is_drawed_img LIMIT ? OFFSET ?|1|1|1||0|0|145452|145452|5|5|
|v4_coupon|SELECT * FROM `coupon`|1|9|9||0|0|1263435|1263435|1263435|1263435|
|tenant|SELECT * FROM `erp_employee`|1|4|4||0|0|88905|88905|88905|88905|
|item_manage|SELECT * FROM `task`|1|1|1||0|0|65359|65359|65359|65359|
|account|SELECT * FROM (SELECT t?.id,t?.tenant_id,t?.tenant_app_id,t?.share_user_id AS user_id,t?.user_name AS user_name,t?.share_user_type AS user_identity,t?.business_id AS activity_id,t?.activity_name AS activity_name,DATE_FORMAT(oi.finish_time,?) AS busi_date,count(*) AS deal_amount,ifnull(sum(oi.total_fee),?) AS deal_money FROM goods.`share` t? JOIN goods.share_detail sd ON t?.id=sd.share_id JOIN ORDER.order_info oi ON sd.order_id=oi.id AND oi.tenant_wechatapp_id=? AND oi.status=? JOIN activity_service.activity t? ON t?.business_id=t?.id JOIN user_service.tenant_member t? ON t?.tenant_id=t?.tenant_id AND t?.tenant_app_id=t?.tenant_app_id AND t?.share_user_id=t?.user_id WHERE t?.tenant_app_id=? AND t?.share_user_type=? AND t?.business_type!=? AND oi.finish_time>=? AND oi.finish_time<=? GROUP BY t?.id,DATE_FORMAT(oi.finish_time,?) UNION ALL SELECT t?.id,t?.tenant_id,t?.tenant_app_id,t?.share_user_id AS user_id,t?.employee_name AS user_name,t?.share_user_type AS user_identity,t?.business_id AS activity_id,t?.activity_name AS activity_name,DATE_FORMAT(oi.finish_time,?) AS busi_date,count(*) AS deal_amount,ifnull(sum(oi.total_fee),?) AS deal_money FROM goods.`share` t? JOIN goods.share_detail sd ON t?.id=sd.share_id JOIN ORDER.order_info oi ON sd.order_id=oi.id AND oi.tenant_wechatapp_id=? AND oi.status=? JOIN activity_service.activity t? ON t?.business_id=t?.id JOIN tenant.employee t? ON t?.share_user_id=t?.id WHERE t?.tenant_app_id=? AND t?.share_user_type=? AND t?.business_type!=? AND oi.finish_time>=? AND oi.finish_time<=? GROUP BY t?.id,DATE_FORMAT(oi.finish_time,?))tt ORDER BY tt.id ASC LIMIT ? OFFSET ?|1|1|1||0|0|3080|3080|0|0|
|v4_sales|SELECT * FROM `warranty`|1|19|19||0|0|2747194|2747194|2747194|2747194|
|export|SELECT pc.id,pc.cutomer_grade AS cutomerGrade,ifnull(mem.member_name,ifnull(eu.external_user_name,?)) AS `name`,mem.mobile_no,pc.maintain_employee_name AS maintainEmployee,pc.last_maintain_time,(CASE WHEN pc.`status`=? THEN pc.finish_time ELSE ? END)dealTime,pc.maintain_num AS maintainNum,pc.intention_num,pc.latest_intention,sp.`name` AS maintainShop,pc.`status`,(CASE pc.`status` WHEN ? THEN ? ELSE ? END) AS statusName,pc.fail_employee_name AS failEmployee,pc.checkin_time,pc.finish_time AS finishTime FROM v4_user.potential_customer pc LEFT JOIN (SELECT t?.tenant_id,ifnull(t?.member_name,t?.external_user_name) AS external_user_name,t?.external_user_id FROM v4_user.cwx_external_user t? LEFT JOIN v4_user.member t? ON t?.tenant_id=? AND t?.tenant_app_id=? AND t?.external_user_id=t?.external_user_id WHERE t?.tenant_id=?)eu ON pc.tenant_id=eu.tenant_id AND pc.external_user_id=eu.external_user_id LEFT JOIN v4_user.member mem ON pc.tenant_id=mem.tenant_id AND pc.member_id=mem.id AND mem.`status`=? LEFT JOIN v4_employee.shop sp ON pc.maintain_shop_id=sp.id WHERE pc.tenant_id=? AND pc.tenant_app_id=? AND EXISTS (SELECT ? FROM v4_user.potential_customer_maintain t? WHERE pc.id=t?.potential_customer_id AND t?.create_time>=? AND t?.create_time<=? AND t?.event_type IN(?)) ORDER BY pc.id DESC|1|1|1||0|0|10176|10176|523|523|
|erp_sync|SELECT * FROM `cwx_checkin_sync_log`|1|6|6||0|0|267997|267997|267997|267997|
|v4_user|SELECT * FROM `employee_external_bind`|1|37|37||0|0|7614008|7614008|7614008|7614008|
|tenant|SELECT * FROM `employee_qrcode`|1|2|2||0|0|66697|66697|66697|66697|
