提交 afbda8d1 authored 作者: zengzhi's avatar zengzhi

auto commit

上级 00f9b9e0
# 2020年04月25日运行日报:https://git.sjfx.com.cn/report/daily/blob/master/2020-04-25/daily.md
## 服务器情况
|服务器 |CPU使用率 |内存使用率 |主硬盘使用率 |查看详情 |
| :- | :-: | :-: | :-: | :- |
|v3nginx |- |- |- |http://47.98.156.252:17123/|
|v3-publish |44.9% |60.5% |64% |http://47.110.9.96:17123/|
|v3-base-mq001 |3.91% |71.8% |35.8% |http://114.55.171.242:17123/|
|v3-base-mq002 |4.38% |72.1% |26.5% |http://47.110.226.218:17123/|
|proxy-local |2.62% |67.6% |23.7% |http://47.96.14.81:17123/|
|v3eureka001 |8.95% |68.4% |28.3% |http://47.110.137.241:17123/|
|v3eureka002 |9.43% |**83.4%** |38.8% |http://114.55.171.107:17123/|
|v3-gateway001 |2.89% |60.5% |57.6% |http://47.111.11.230:17123/|
|v3-gateway002 |2.12% |45% |60.2% |http://47.110.14.10:17123/|
|v3-gateway003 |2.68% |78.8% |54.7% |http://47.110.12.94:17123/|
|v3-gateway004 |2.76% |77% |54.5% |http://114.55.169.175:17123/|
|v3-BS-F001 |5.76% |75.9% |19.9% |http://47.98.220.95:17123/|
|v3-BS-F002 |9.12% |61.8% |22.8% |http://47.111.105.30:17123/|
|v3-BS-F003 |6.23% |77.9% |27.4% |http://47.111.105.137:17123/|
|v3-BS-F004 |6.58% |**82.8%** |23.1% |http://47.111.105.218:17123/|
|v3-BS-H001 |5.04% |76.4% |19.8% |http://47.111.169.175:17123/|
|v3-BS-H002 |8.62% |63.5% |22.8% |http://114.55.171.6:17123/|
|v3-BS-H003 |5.5% |**81.6%** |27.5% |http://47.111.186.205:17123/|
|v3-BS-H004 |5.97% |**81.7%** |23.3% |http://114.55.209.3:17123/|
|v3-BS-G001 |6.48% |78.1% |19.1% |http://114.55.243.46:17123/|
|v3-BS-G002 |22.4% |63.2% |30.9% |http://47.98.158.5:17123/|
|v3-BS-G003 |5.51% |**83.6%** |24.9% |http://47.98.220.48:17123/|
|v3-BS-G004 |5.84% |75.6% |24.8% |http://47.111.79.177:17123/|
|v3-BS-I001 |5.28% |78.8% |21.6% |http://114.55.243.77:17123/|
|v3-BS-I002 |22.9% |64.9% |30.6% |http://114.55.242.246:17123/|
|v3-BS-I003 |5.91% |**81.1%** |19.5% |http://47.110.15.201:17123/|
|v3-BS-I004 |5.19% |**82.8%** |24.2% |http://114.55.243.68:17123/|
|v3-tag |2.38% |79.5% |23.2% |http://47.110.13.5:17123/|
## 数据库情况
### rm-bp1qn4bl8d8p9mnm4
内存使用率: 最小值 39.06% 最大值 39.51% 平均值 0.0274565670604587%
CPU使用率: 最小值 1.12% 最大值 100% 平均值 13.9971855455177%
每秒IO请求次数: 最小值 0 最大值 3060.67 平均值 106.985170257123
连接数: 最小值 409.02 最大值 430.27 平均值 419.387025712301
活跃连接数: 最小值 0 最大值 3.98 平均值 0.321111883252256
空间使用量: 总使用量;86655.14MB 数据使用量;80071.43MB 日志使用量;2096.86MB 临时使用量;0.06MB 系统使用量:4486.79MB
### rr-bp13k3q7292ce5t6k
内存使用率: 最小值 33.98% 最大值 33.98% 平均值 33.98%
CPU使用率: 最小值 2.55% 最大值 2.55% 平均值 2.55%
每秒IO请求次数: 最小值 32.03 最大值 32.03 平均值 32.03
连接数: 最小值 60 最大值 60 平均值 60
活跃连接数: 最小值 0.04 最大值 0.04 平均值 0.04
空间使用量: 总使用量;85598.5MB 数据使用量;79913.14MB 日志使用量;2534.46MB 临时使用量;0.01MB 系统使用量:3150.9MB
### rm-bp1piz35u161jjc92
内存使用率: 最小值 46.86% 最大值 46.87% 平均值 5.20777777777778%
CPU使用率: 最小值 0.19% 最大值 60.9% 平均值 18.2633333333333%
每秒IO请求次数: 最小值 3.83 最大值 2219.99 平均值 534.88
连接数: 最小值 83 最大值 83.98 平均值 83.1233333333333
活跃连接数: 最小值 0 最大值 3.58 平均值 0.97
空间使用量: 总使用量;56957.53MB 数据使用量;46116.95MB 日志使用量;4695.6MB 临时使用量;2.15MB 系统使用量:6142.83MB
慢日志:[rm-bp1qn4bl8d8p9mnm4](rm-bp1qn4bl8d8p9mnm4slowsql.md)
慢日志(excel):[rm-bp1qn4bl8d8p9mnm4](rm-bp1qn4bl8d8p9mnm4slowsql.xlsx)
慢日志:[rm-bp1piz35u161jjc92](rm-bp1piz35u161jjc92slowsql.md)
慢日志(excel):[rm-bp1piz35u161jjc92](rm-bp1piz35u161jjc92slowsql.xlsx)
## zookeeper当前情况
zk_version 3.4.12-e5259e437540f349646870ea94dc2658c4e44b3b, built on 03/27/2018 03:55 GMT
zk_avg_latency 0
zk_max_latency 966
zk_min_latency 0
zk_packets_received 90579373
zk_packets_sent 90668297
zk_num_alive_connections 41
zk_outstanding_requests 0
zk_server_state leader
zk_znode_count 3151
zk_watch_count 853
zk_ephemerals_count 1766
zk_approximate_data_size 998729
zk_open_file_descriptor_count 75
zk_max_file_descriptor_count 1048576
zk_followers 3
zk_synced_followers 3
zk_pending_syncs 0
## Redis情况
Cpu使用率:0.60%
已用内存:117088600.00Byte
每秒总访问量:147.92
已用连接数:1495.67
键总数:24855.00
设置过期时间的key数量:24848.00
每秒请求次数:67.60 最大每秒请求次数:492.77
每秒回复次数:1135.25 最大每秒回复次数:6815.19
## 昨日注册情况
![register](register.jpg)
[url](http://kibana.sjfx.com.cn/app/kibana#/visualize/edit/19697bf0-85e1-11e9-b79e-3bd17e684a34?embed=true&_g=(refreshInterval%3A(pause%3A!t%2Cvalue%3A0)%2Ctime%3A(from%3A'2020-04-24T16%3A00%3A00.000Z'%2Cmode%3Aabsolute%2Cto%3A'2020-04-25T15%3A59%3A59.999Z')))
## 7日注册情况
![7register](7register.jpg)
[url](http://kibana.sjfx.com.cn/app/kibana#/visualize/edit/ef3e87a0-86a1-11e9-b79e-3bd17e684a34?embed=true&_g=(refreshInterval%3A(pause%3A!t%2Cvalue%3A0)%2Ctime%3A(from%3A'2020-04-17T16%3A00%3A00.000Z'%2Cmode%3Aabsolute%2Cto%3A'2020-04-25T15%3A59%3A59.999Z')))
## 昨日访问情况
![vistpai](vistpai.jpg)
[url](http://kibana.sjfx.com.cn/app/kibana#/visualize/edit/8aee1530-86a7-11e9-b79e-3bd17e684a34?embed=true&_g=(refreshInterval%3A(pause%3A!t%2Cvalue%3A0)%2Ctime%3A(from%3A'2020-04-24T16%3A00%3A00.000Z'%2Cmode%3Aabsolute%2Cto%3A'2020-04-25T15%3A59%3A59.999Z')))
![visttable](visttable.jpg)
[url](http://kibana.sjfx.com.cn/app/kibana#/visualize/edit/94ad9340-86a5-11e9-b79e-3bd17e684a34?embed=true&_g=(refreshInterval%3A(pause%3A!t%2Cvalue%3A0)%2Ctime%3A(from%3A'2020-04-24T16%3A00%3A00.000Z'%2Cmode%3Aabsolute%2Cto%3A'2020-04-25T15%3A59%3A59.999Z')))
## 昨日请求数
![reqcount](reqcount.jpg)
[url](http://kibana.sjfx.com.cn/app/kibana#/visualize/edit/35503f30-86a8-11e9-b79e-3bd17e684a34?embed=true&_g=(refreshInterval%3A(pause%3A!t%2Cvalue%3A0)%2Ctime%3A(from%3A'2020-04-24T16%3A00%3A00.000Z'%2Cmode%3Aabsolute%2Cto%3A'2020-04-25T15%3A59%3A59.999Z')))
## 7日请求数
![7reqcount](7reqcount.jpg)
[url](http://kibana.sjfx.com.cn/app/kibana#/visualize/edit/b810fea0-86a8-11e9-b79e-3bd17e684a34?embed=true&_g=(refreshInterval%3A(pause%3A!t%2Cvalue%3A0)%2Ctime%3A(from%3A'2020-04-17T16%3A00%3A00.000Z'%2Cmode%3Aabsolute%2Cto%3A'2020-04-25T15%3A59%3A59.999Z')))
|数据库名称|SQL语句|总执行次数|总执行时间(秒)|最大执行时长|平均执行时间|锁定总时长|最大锁定时长|解析总行数|解析最大行数|返回总行数|返回最大行数|
| - | - | - | - | - | - | - | - | - | - | - | - |
|数据库名称|SQL语句|总执行次数|总执行时间(秒)|最大执行时长|平均执行时间|锁定总时长|最大锁定时长|解析总行数|解析最大行数|返回总行数|返回最大行数|
| - | - | - | - | - | - | - | - | - | - | - | - |
|gift_mail|select count ( 0 ) from ( select p.* , sp.take_type , ifnull ( pp.integral_price , ifnull ( ( select min ( inventory.price ) from inventory where inventory.product_id = p.id ) , :1 ) ) as price , ifnull ( t.quantity , :2 ) quantity , pt.partner_name vendorname , 0.0 distance , c.categroy_name categroy_name , pp.partner_id from product p inner join category c on c.id = p.category_id left outer join self_product sp on p.id = sp.product_id left outer join partner_product pp on p.id = pp.product_id left outer join partner pt on pt.id = pp.partner_id left outer join ( select product_id , sum ( quantity ) quantity from gift_mail.inventory group by product_id ) t on p.id = t.product_id where ( ( p.is_disable is null or p.is_disable = :3 ) ) ) as p where ( p.tenant_id = :4 and p.product_type = :5 )|131|198|2||0|0|2532468|19370|131|1|
|gift_mail|select * from ( select p.* , sp.take_type , ifnull ( pp.integral_price , ifnull ( ( select min ( inventory.price ) from inventory where inventory.product_id = p.id ) , :1 ) ) as price , ifnull ( t.quantity , :2 ) quantity , pt.partner_name vendorname , 0.0 distance , c.categroy_name categroy_name , pp.partner_id from product p inner join category c on c.id = p.category_id left outer join self_product sp on p.id = sp.product_id left outer join partner_product pp on p.id = pp.product_id left outer join partner pt on pt.id = pp.partner_id left outer join ( select product_id , sum ( quantity ) quantity from gift_mail.inventory group by product_id ) t on p.id = t.product_id where ( ( p.is_disable is null or p.is_disable = :3 ) ) ) as p where ( p.tenant_id = :4 and p.product_type = :5 ) order by p.id desc limit :6|106|158|2||0|0|2051572|19390|1994|34|
|platform|select count ( 1 ) from `salesdetaillog` where `vendorid` = :1 and `noteid` = :2|66|107|3||0|0|1918696|34871|66|1|
|user_service|select count ( * ) from tenant_user t1 left join user_employee t3 on t1.user_id = t3.user_id and t1.tenant_app_id = t3.tenant_wechatapp_id where t3.id is null and t1.mobile_no is not null and t1.mobile_no != :1 and t1.shop_id = :2 and t1.tenant_app_id = :3|61|318|13||0|0|4406633|179816|61|1|
|platform|select `tasktype` , `tasktime` , `taskstatus` , `bid` , `vendorid` , `uid` , `completetime` , `remark` , `createtime` , `id` from `taskassignment` where tasktype = :1 and vendorid = :2 and date_format ( tasktime , :3 ) >= curdate ( ) and ( taskstatus = :4 or taskstatus = :5 )|39|60|2||0|0|29645076|760144|18|6|
|platform|select count ( 1 ) from `integrallog` where `vendorid` = :1 and `changefrom` = :2 and `changeid` = :3|30|45|2||0|0|731474|32732|30|1|
|authorization_service|select id , user_id , tenant_id , tenant_wx_app_id , account_id , login_way , login_code , login_token , roles , status , expire_time , create_time , update_time , login_ip , login_time , login_data , employee_id , shop_id from user_login_token where ( tenant_id = :1 and account_id = :2 and status = :3 )|29|45|3||0|0|6610383|373158|58|3|
|authorization_service|select id , user_id , tenant_id , tenant_wx_app_id , account_id , login_way , login_code , login_token , roles , status , expire_time , create_time , update_time , login_ip , login_time , login_data , employee_id , shop_id from user_login_token where employee_id = :1 and tenant_id = :2 and tenant_wx_app_id = :3 and shop_id = :4 and login_way = :5 and status = :6|29|53|8||0|0|1973388|119202|30|2|
|platform|select count ( 1 ) from coupondetail cd where getuid = :1 and ( couponstate = :2 or couponstate = :3 ) and date_format ( expirytime , :4 ) >= curdate ( )|28|63|3||0|0|9022552|322234|28|1|
|platform|select `typefullname` , `methodname` , `arguments` , `partition` , `offset` , `createtime` , `updatetime` , `retried` , `errormsg` , `id` from `pushlog` where `typefullname` = :1 and `methodname` = :2 and `arguments` = :3|28|52|2||0|0|7134829|254849|0|0|
|value_added|select id , template_name as templatename , added_percent_per_day as addedpercentperday , add_days as adddays , keeping_days as keepingdays , devalue_percent_per_day as devaluepercentperday , exchange_days as exchangedays , is_disable as isdisable , effective_days as effectivedays , ifnull ( usenumber , 0 ) as usenumber , generator_method as generatormethod , remark as remark from value_added_template left join ( select template_id , count ( * ) usenumber from value_added_user where tenant_wechatapp_id = :1 group by template_id ) value_added_user on value_added_template.id = value_added_user.template_id where tenant_wechatapp_id = :2 and id = :3|21|29|2||0|0|1344882|77419|21|1|
|user_service|select ue.employee_id as employeeid , count ( * ) as quantity from user_service.user_employee ue join user_service.tenant_user tu on ue.tenant_wechatapp_id = tu.tenant_app_id and ue.user_id = tu.user_id where employee_id in ( :1 ) and ue.tenant_wechatapp_id = :2 and tu.shop_id = :3 group by ue.employee_id|19|23|1||0|0|1363553|102237|19|1|
|tenant|select id , sales_no , sales_date , member_erp_id , sales_erp_id , is_sales from erp_sales where sales_no like concat ( :1 , :2 , :3 ) and sales_status = :4 and tenant_id = :5 and tenant_wechatapp_id = :6 order by sales_date desc limit :7|16|38|4||0|0|3930050|520417|5|1|
|facepass_sync|select id , tenant_id , tenant_wechatapp_id , shop_id , status , create_time , update_time , receive_data , response_data from customer_face_sync_message where status = :1 and create_time < date_add ( now ( ) , interval :2 minute ) order by id asc limit :3|12|15|2||0|0|476409|43279|0|0|
|warranty_service|select *from warranty_service.warranty where tenant_wechatapp_id = :1 and upload_frequency <= :2 and version = :3 and warranty_img_url is null|12|29|8||0|0|419066|90491|0|0|
|user_service|select count ( 0 ) from ( select t1.user_id as userid , t2.head_img_url as headimgurl , t2.nick_name as nickname , t1.mobile_no as mobileno , t1.is_subscribe as subscribe , t1.sex , t1.tenant_union_id as tenantunionid , date_format ( t1.bind_time , '%y-%m-%d%h:%i:%s' ) as registertime , t1.id as tenantuserid from tenant_user t1 join `user` t2 on t1.user_id = t2.id left join user_employee t3 on t1.user_id = t3.user_id and t1.tenant_id = t3.tenant_id and t1.tenant_app_id = t3.tenant_wechatapp_id where t3.id is null and t1.mobile_no is not null and t1.mobile_no != :1 and t1.shop_id = :2 and t1.tenant_id = :3 and t1.tenant_app_id = :4 ) table_count|10|18|4||0|0|774053|199908|10|1|
|authorization_service|update user_login_token set status = :1 , update_time = now ( ) where employee_id = :2 and tenant_id = :3 and tenant_wx_app_id = :4 and shop_id = :5 and login_way = :6 and status = :7|10|12|1||0|0|1045150|119101|0|0|
|platform|select `noteid` , `vendorid` , `detailindex` , `productname` , `productbarcode` , `category` , `salestype` , `quantity` , `amount` , `integral` , `productdesc` , `slid` , `paidamount` , `id` from `salesdetaillog` where `noteid` = :1 and `vendorid` = :2|8|18|3||0|0|198110|26862|16|3|
|authorization_service|update user_login_token set status = :1 where user_id = :2 and tenant_id = :3 and tenant_wx_app_id = :4 and login_way = :5|8|12|2||0|0|3057|742|0|0|
|employee|select * from backlog where tenant_app_id = :1 and employee_id = :2 and status in ( :3 , :4 ) and shop_id = :5 and scene = :6 and expire_time >= :7 order by create_time desc limit :8|7|17|3||0|0|1348664|193291|24|7|
|erp_sync|select * from erp_sync.retry_data where ( need_erp_member_id = :1 or ( need_erp_member_id = :2 and erp_member_id is not null ) ) and retry_times > :3 order by id asc|7|14|4||0|0|819048|117142|21|3|
|platform|update vendormember vm inner join ( select sum ( integral ) as integral , sum ( if ( integral > 0 , integral , 0 ) ) as hisintegral from integrallog where vendorid = :1 and memberid = :2 and isdeleted = :3 ) s on :4 = :5 set vm.integral = ifnull ( s.integral , :6 ) , vm.hisintegral = ifnull ( s.hisintegral , :7 ) , vm.updatetime = now ( ) where vendorid = :8 and memberid = :9|5|6|1||0|0|62|33|0|0|
|user_service|select * from user_employee where employee_erp_id = :1 and tenant_id = :2 and date_format ( update_time , :3 ) = date_format ( now ( ) , :4 )|4|4|1||0|0|5977792|1494871|1115|1084|
|gift_mail|select * from ( select p.* , sp.take_type , ifnull ( pp.integral_price , ifnull ( ( select min ( inventory.price ) from inventory where inventory.product_id = p.id ) , :1 ) ) as price , ifnull ( t.quantity , :2 ) quantity , pt.partner_name vendorname , 0.0 distance , c.categroy_name categroy_name , pp.partner_id from product p inner join category c on c.id = p.category_id left outer join self_product sp on p.id = sp.product_id left outer join partner_product pp on p.id = pp.product_id left outer join partner pt on pt.id = pp.partner_id left outer join ( select product_id , sum ( quantity ) quantity from gift_mail.inventory group by product_id ) t on p.id = t.product_id where ( ( p.is_disable is null or p.is_disable = :3 ) ) ) as p where ( p.tenant_id = :4 and p.product_type = :5 ) order by p.id desc limit :6 , :7|4|6|1||0|0|77588|19412|66|20|
|user_service|select count ( * ) from tenant_user where tenant_app_id = :1 and shop_id = :2 and mobile_no is not null and mobile_no != :3|4|18|10||0|0|264193|149791|4|1|
|coupon_service|select count ( * ) from coupon where ( coupon_state = :1 and user_id = :2 and tenant_app_id = :3 and end_time > :4 )|3|4|1||0|0|307498|102502|3|1|
|platform|select vm.* from vendormember vm join member m on vm.id = m.vendormemberid and vm.vendorid = m.vendorid where m.employeeid = :1 and vm.vendorid = :2 and ( ( birthdaytype = :3 and month ( birthday ) = month ( date_sub ( curdate ( ) , interval :4 day ) ) and day ( birthday ) = day ( date_sub ( curdate ( ) , interval :5 day ) ) ) or ( birthdaytype = :6 and month ( birthday ) = month ( date_sub ( :7 , interval :8 day ) ) and day ( birthday ) = day ( date_sub ( :9 , interval :10 day ) ) ) )|3|7|3||0|0|98089|62557|72|59|
|wx_gateway|select * from wx_user where user_id = :1 and open_id not like :2 limit :3|2|14|7||0|0|3529216|1764608|2|1|
|sms|select count ( 0 ) from ( select a.phone_numbers as phoneno , concat ( '【' , a.sign_name , '】' , case when b.content is not null then b.content when stc.content is not null then stc.content else a.template_param end ) as content , a.template_code , a.out_id as outid , a.template_param , a.create_time as sendtime , a.create_time as recevietime , a.code as state , a.send_count , a.message , a.source_type from sms_send a left join sms_template b on a.template_code = b.code left join sms_template_custom stc on a.tenant_app_id = stc.tenant_app_id and a.template_code = stc.code and stc.status = :1 where a.tenant_app_id = :2 and a.phone_numbers like concat ( :3 , :4 , :5 ) ) table_count|2|4|2||0|0|15660|7835|2|1|
|sms|select count ( 0 ) from ( select a.phone_numbers as phoneno , concat ( '【' , a.sign_name , '】' , case when b.content is not null then b.content when stc.content is not null then stc.content else a.template_param end ) as content , a.template_code , a.out_id as outid , a.template_param , a.create_time as sendtime , a.create_time as recevietime , a.code as state , a.send_count , a.message , a.source_type from sms_send a left join sms_template b on a.template_code = b.code left join sms_template_custom stc on a.tenant_app_id = stc.tenant_app_id and a.template_code = stc.code and stc.status = :1 where a.tenant_app_id = :2 ) table_count|2|16|8||0|0|515323|257717|2|1|
|employee|select count ( 0 ) from backlog where tenant_app_id = :1 and employee_id = :2 and status in ( :3 , :4 ) and shop_id = :5 and scene = :6 and expire_time >= :7|2|2|1||0|0|8455|4806|2|1|
|employee|update backlog set leave_flag = :1 where tenant_app_id = :2 and employee_id = :3|2|5|4||0|0|237963|193291|0|0|
|erp_sync|select * from retry_data where tenant_app_id = :1 and user_id = :2|2|2|1||0|0|16512|10166|1|1|
|user_service|select count ( 0 ) from tenant_user tu join user u on u.id = tu.user_id where tu.tenant_id = :1 and ( tu.user_name like concat ( :2 , :3 , :4 ) or tu.mobile_no = :5 or u.nick_name like concat ( :6 , :7 , :8 ) ) and tenant_app_id = :9|2|20|11||0|0|106836|53418|2|1|
|employee|select * from backlog where tenant_app_id = :1 and employee_id = :2 and status in ( :3 , :4 ) and shop_id = :5 and scene in ( :6 , :7 ) and expire_time >= :8 order by create_time desc limit :9|2|4|3||0|0|382209|193291|11|6|
|warranty_service|select count ( * ) from warranty where user_id = :1 and tenant_wechatapp_id = :2 and is_disable = :3|1|1|1||0|0|2239|2239|1|1|
|coupon_service|select count ( 0 ) from ( select c.id , c.coupon_name , c.coupon_type , round ( c.face_value / 100 , 2 ) as facevalue , round ( c.discount / 10 , 1 ) as discount , c.begin_time , c.end_time , c.wx_card_id , c.wx_card_no , c.template_id , round ( c.use_threshold / 100 ) as usethreshold , t.scope , ce.product_name , ( case when c.end_time < now ( ) then 'invalid' when c.begin_time > now ( ) then 'not_effective' else c.coupon_state end ) as state from coupon_service.coupon c join coupon_service.coupon_extend ce on ce.id = c.id join coupon_service.template t on t.id = c.template_id where c.tenant_app_id = :1 and c.user_id = :2 ) as c|1|1|1||0|0|49693|49693|1|1|
|order|select max ( create_time ) from `order`.order_operator_log where tenant_wechatapp_id = :1 and order_id = :2|1|1|1||0|0|302731|302731|1|1|
|platform|select count ( 1 ) from `smssent` where vendorid = :1 and success = true and date_sub ( date ( :2 ) , interval :3 day ) = date_format ( senttime , :4 )|1|2|2||0|0|66068|66068|1|1|
|mysql|delete from wx_gateway.wx_template_msg where create_time < date_sub ( now ( ) , interval :1 day )|1|25|25||0|0|915623|915623|0|0|
|platform|select ifnull ( eid , 0 ) as eid , ifnull ( shopid , 0 ) as sid , vendorid , count ( 1 ) as quantity from productcerts where vendorid = :1 and to_days ( :2 ) :3 to_days ( createtime ) = :4 group by eid , shopid , vendorid|1|1|1||0|0|28984|28984|0|0|
|value_added|-- 增值达到最大天数 select 'value_added_limit_contact' as limitdaytype , tenant_wechatapp_id as tenantappid , user_id as userid , group_concat ( t.product_barcode order by product_barcode asc ) as productcode , group_concat ( t.product_name order by product_barcode asc ) as productname from value_added_user t where tenant_wechatapp_id = :1 and state = :2 and t.start_add_time >= date_add ( date_format ( :3 , :4 ) , interval :5 * ( add_days-1 ) day ) and t.start_add_time < date_add ( date_format ( :6 , :7 ) , interval ( :8 * ( add_days-1 ) :9 :10 ) day ) group by tenant_wechatapp_id , user_id|1|1|1||0|0|17430|17430|4|4|
|user_service|select ue.employee_id as employeeid , count ( * ) as quantity from user_service.user_employee ue join user_service.tenant_user tu on ue.tenant_wechatapp_id = tu.tenant_app_id and ue.user_id = tu.user_id where employee_id in ( :1 , :2 , :3 , :4 , :5 , :6 , :7 , :8 , :9 , :10 , :11 , :12 , :13 , :14 , :15 , :16 , :17 , :18 , :19 , :20 ) and ue.tenant_wechatapp_id = :21 and tu.shop_id = :22 group by ue.employee_id|1|2|2||0|0|118664|118664|9|9|
|platform|select vm.* from vendormember vm join member m on vm.id = m.vendormemberid and vm.vendorid = m.vendorid where m.employeeid = :1 and vm.vendorid = :2 and ( ( memorialtype = :3 and month ( memorialday ) = month ( date_sub ( curdate ( ) , interval :4 day ) ) and day ( memorialday ) = day ( date_sub ( curdate ( ) , interval :5 day ) ) ) or ( memorialtype = :6 and month ( memorialday ) = month ( date_sub ( :7 , interval :8 day ) ) and day ( memorialday ) = day ( date_sub ( :9 , interval :10 day ) ) ) )|1|1|1||0|0|16756|16756|0|0|
||load data local infile 'import_data/966118544792166400_20200425151804_1_member.csv' replace into table user_service.erp_member character set utf8mb4 fields terminated by :1 lines starting by :2 ( tenant_id , tenant_wechatapp_id , member_erp_id , employee_erp_id , grade_erp_id , card_no , dept_erp_id , mobile_no , consumption_integral , user_name , @sex , @birthday , @birthday_is_lunar , @home_address , @memorialday , @memorialday_name , @memorialday_is_lunar , @interested , @amount , erp_create_time , status ) set update_time = now ( )|1|4|4||0|0|0|0|0|0|
|coupon_service|select * from coupon_user where datediff ( date_format ( end_time , :1 ) , date_format ( now ( ) , :2 ) ) = :3 and coupon_state in ( :4 )|1|9|9||0|0|792948|792948|116|116|
|activity_service|select count ( 0 ) from activity_service.user_trace ut left join activity_service.activity at on ut.activity_id = at.id where ut.step = :1 and ut.status = :2 and ut.activity_id = :3|1|9|9||0|0|1105642|1105642|1|1|
||load data local infile 'import_data/966118544792166400_20200425151804_1_member.csv' replace into table user_service.erp_member_info character set utf8mb4 fields terminated by :1 lines starting by :2 ( tenant_id , tenant_wechatapp_id , erp_member_id , @employee_erp_id , @grade_erp_id , @card_no , @dept_erp_id , mobile_no , @consumption_integral , user_name , sex , birthday , birthday_is_lunar , home_address , memorialday , memorialday_name , memorialday_is_lunar , interested , amount , erp_create_time , @status ) set update_time = now ( )|1|2|2||0|0|0|0|0|0|
|message_push|delete from message_log where create_time < :1|1|16|16||0|0|187034|187034|0|0|
|platform|select `vendorid` , `memberid` , `salesdate` , `noteid` , `noteno` , `empid` , `empname` , `amounttotal` , `quantitytotal` , `integraltotal` , `salesstoreid` , `staffattitude` , `professionallevel` , `appearance` , `storeimage` , `productdisplay` , `salescomment` , `commenttime` , `replycontent` , `replytime` , `replyuser` , `tipfee` , `tipmorderid` , `tippayno` , `tippaytime` , `status` , `aftersalesremark` , `uid` , `eid` , `sid` , `id` from `saleslog` where vendorid = :1 and tipfee > :2 and tippayno is not null and date_sub ( date ( :3 ) , interval :4 day ) = date_format ( tippaytime , :5 )|1|5|5||0|0|120774|120774|0|0|
|order|select od.id from order_info od left join order_detail dt on od.id = dt.order_id where od.status = :1 and dt.sku_id = :2 and od.user_id = :3|1|1|1||0|0|77897|77897|0|0|
|value_added|-- 根据添加时间得出当前增值金额 update value_added_user set amount_added = if ( :1 > ( ( ( added_percent_per_day / :2 ) * if ( :3 >= timestampdiff ( day , date_format ( start_add_time , :4 ) , now ( ) ) :5 :6 :7 add_days , timestampdiff ( day , date_format ( start_add_time , :8 ) , now ( ) ) :9 :10 , add_days ) ) :11 ( ( devalue_percent_per_day / :12 ) * if ( :13 >= timestampdiff ( day , date_format ( start_add_time , :14 ) , now ( ) ) :15 :16 :17 add_days :18 keeping_days , :19 , timestampdiff ( day , date_format ( start_add_time , :20 ) , now ( ) ) :21 :22 :23 add_days :24 keeping_days ) ) ) * amount_pay , :25 , ( ( ( added_percent_per_day / :26 ) * if ( :27 >= timestampdiff ( day , date_format ( start_add_time , :28 ) , now ( ) ) :29 :30 :31 add_days , timestampdiff ( day , date_format ( start_add_time , :32 ) , now ( ) ) :33 :34 , add_days ) ) :35 ( ( devalue_percent_per_day / :36 ) * if ( :37 >= timestampdiff ( day , date_format ( start_add_time , :38 ) , now ( ) ) :39 :40 :41 add_days :42 keeping_days , :43 , timestampdiff ( day , date_format ( start_add_time , :44 ) , now ( ) ) :45 :46 :47 add_days :48 keeping_days ) ) ) * amount_pay ) , update_time = now ( ) where state = :49 and update_time <= curdate ( ) and ( start_add_time >= date_add ( curdate ( ) , interval :50 ( add_days :51 keeping_days :52 :53 ) day ) or ( amount_added > :54 and start_add_time < date_add ( curdate ( ) , interval :55 ( add_days :56 keeping_days :57 :58 ) day ) ) ) -- 判断条件 在增值时间内 增值金大于0 状态正常|1|2|2||0|0|324678|324678|0|0|
|mysql|insert into erp_sync.sync_record_20190924 select * from erp_sync.sync_record where create_time < date_sub ( now ( ) , interval :1 day )|1|10|10||0|0|562734|562734|0|0|
|sms|select count ( 0 ) from ( select a.phone_numbers as phoneno , concat ( '【' , a.sign_name , '】' , case when b.content is not null then b.content when stc.content is not null then stc.content else a.template_param end ) as content , a.template_code , a.out_id as outid , a.template_param , a.create_time as sendtime , a.create_time as recevietime , a.code as state , a.send_count , a.message , a.source_type from sms_send a left join sms_template b on a.template_code = b.code left join sms_template_custom stc on a.tenant_app_id = stc.tenant_app_id and a.template_code = stc.code and stc.status = :1 where a.phone_numbers like concat ( :2 , :3 , :4 ) ) table_count|1|15|15||0|0|1865366|1865366|0|0|
|platform|select count ( 1 ) from coupondetail where vendorid = :1 and coupontype = :2 and couponstate = :3 and to_days ( :4 ) :5 to_days ( createtime ) = :6|1|3|3||0|0|322234|322234|1|1|
|tenant|select count ( * ) from user_service.tenant_user|1|2|2||0|0|3792682|3792682|1|1|
|tenant|select count ( 0 ) from tenant.erp_sales es left join tenant.tenant_wechatapp_shop shop on shop.tenant_wechatapp_id = es.tenant_wechatapp_id and shop.dept_erp_id = es.dept_erp_id join tenant.employee e on e.tenant_id = es.tenant_id and e.employee_erp_id = es.employee_erp_id join tenant.employee_shop esh on esh.tenant_app_id = es.tenant_wechatapp_id and esh.employee_id = e.id and esh.dept_erp_id = es.dept_erp_id where es.tenant_wechatapp_id = :1 and es.dept_erp_id = :2 and es.comment_id is not null and es.comment_id != :3 and esh.status in ( :4 , :5 )|1|1|1||0|0|55419|55419|1|1|
|order|select id from order_operator_log where tenant_wechatapp_id = :1 and order_id = :2 and ( src_child_status = :3 and dst_child_status = :4 ) order by create_time desc limit :5|1|1|1||0|0|302940|302940|0|0|
|user_service|insert into erp_member_info ( id , tenant_id , tenant_wechatapp_id , erp_member_id , mobile_no , user_name , sex , birthday , birthday_is_lunar , home_address , memorialday , memorialday_name , memorialday_is_lunar , interested , amount , create_time , update_time ) values ( null , :1 , :2 , :3 , :4 , :5 , :6 , :7 , :8 , :9 , :10 , :11 , :12 , :13 , 5685.00 , :14 , :15 ) on duplicate key update erp_member_id = :16 , mobile_no = :17 , user_name = :18 , sex = :19 , birthday = :20 , birthday_is_lunar = :21 , home_address = :22 , memorialday = :23 , memorialday_name = :24 , memorialday_is_lunar = :25 , interested = :26 , amount = 5685.00 , update_time = :27|1|2|2||0|0|0|0|0|0|
|bespoke|select count ( * ) from bespoke.bespoke_trade where user_id = :1 and tenant_app_id = :2 and status <> :3|1|1|1||0|0|57264|57264|1|1|
|user_service|select count ( 0 ) from tenant_user tenantuser join user_service.user user on tenantuser.user_id = user.id where ( tenantuser.tenant_id = :1 and tenantuser.tenant_app_id = :2 and tenantuser.user_id not in ( :3 ) )|1|4|4||0|0|79244|79244|1|1|
# 运行日志
# 2020-04
[2020-04-01](2020-04-01/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-02](2020-04-02/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-06](2020-04-06/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-07](2020-04-07/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-08](2020-04-08/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-09](2020-04-09/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-10](2020-04-10/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-12](2020-04-12/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-13](2020-04-13/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-14](2020-04-14/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-15](2020-04-15/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-16](2020-04-16/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-19](2020-04-19/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-20](2020-04-20/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-21](2020-04-21/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-22](2020-04-22/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-23](2020-04-23/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-24](2020-04-24/daily.md)&ensp;&ensp;&ensp;&ensp;
[2020-04-01](2020-04-01/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-02](2020-04-02/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-06](2020-04-06/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-07](2020-04-07/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-08](2020-04-08/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-09](2020-04-09/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-10](2020-04-10/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-12](2020-04-12/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-13](2020-04-13/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-14](2020-04-14/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-15](2020-04-15/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-16](2020-04-16/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-19](2020-04-19/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-20](2020-04-20/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-21](2020-04-21/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-22](2020-04-22/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-23](2020-04-23/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-24](2020-04-24/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-04-25](2020-04-25/daily.md)&ensp;&ensp;&ensp;&ensp;
# 2020-03
[2020-03-23](2020-03-23/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-03-24](2020-03-24/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-03-25](2020-03-25/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-03-26](2020-03-26/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-03-27](2020-03-27/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-03-29](2020-03-29/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-03-01](2020-03-01/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-03-02](2020-03-02/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-03-03](2020-03-03/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-03-04](2020-03-04/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-03-05](2020-03-05/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-03-06](2020-03-06/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-03-08](2020-03-08/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-03-09](2020-03-09/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-03-10](2020-03-10/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-03-11](2020-03-11/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-03-12](2020-03-12/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-03-15](2020-03-15/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-03-16](2020-03-16/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-03-17](2020-03-17/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-03-18](2020-03-18/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-03-19](2020-03-19/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-03-22](2020-03-22/daily.md)&ensp;&ensp;&ensp;&ensp;
......@@ -11,7 +11,5 @@
# 2020-01
[2020-01-01](2020-01-01/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-01-02](2020-01-02/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-01-05](2020-01-05/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-01-06](2020-01-06/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-01-07](2020-01-07/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-01-08](2020-01-08/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-01-09](2020-01-09/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-01-10](2020-01-10/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-01-12](2020-01-12/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-01-13](2020-01-13/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-01-14](2020-01-14/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-01-15](2020-01-15/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-01-16](2020-01-16/daily.md)&ensp;&ensp;&ensp;&ensp;[2020-01-17](2020-01-17/daily.md)&ensp;&ensp;&ensp;&ensp;
# 2019-12
[2019-12-01](2019-12-01/daily.md)&ensp;&ensp;&ensp;&ensp;[2019-12-02](2019-12-02/daily.md)&ensp;&ensp;&ensp;&ensp;[2019-12-03](2019-12-03/daily.md)&ensp;&ensp;&ensp;&ensp;[2019-12-05](2019-12-05/daily.md)&ensp;&ensp;&ensp;&ensp;[2019-12-08](2019-12-08/daily.md)&ensp;&ensp;&ensp;&ensp;[2019-12-09](2019-12-09/daily.md)&ensp;&ensp;&ensp;&ensp;[2019-12-10](2019-12-10/daily.md)&ensp;&ensp;&ensp;&ensp;[2019-12-11](2019-12-11/daily.md)&ensp;&ensp;&ensp;&ensp;[2019-12-12](2019-12-12/daily.md)&ensp;&ensp;&ensp;&ensp;[2019-12-13](2019-12-13/daily.md)&ensp;&ensp;&ensp;&ensp;[2019-12-15](2019-12-15/daily.md)&ensp;&ensp;&ensp;&ensp;[2019-12-16](2019-12-16/daily.md)&ensp;&ensp;&ensp;&ensp;[2019-12-17](2019-12-17/daily.md)&ensp;&ensp;&ensp;&ensp;[2019-12-18](2019-12-18/daily.md)&ensp;&ensp;&ensp;&ensp;[2019-12-19](2019-12-19/daily.md)&ensp;&ensp;&ensp;&ensp;[2019-12-22](2019-12-22/daily.md)&ensp;&ensp;&ensp;&ensp;[2019-12-24](2019-12-24/daily.md)&ensp;&ensp;&ensp;&ensp;[2019-12-25](2019-12-25/daily.md)&ensp;&ensp;&ensp;&ensp;[2019-12-26](2019-12-26/daily.md)&ensp;&ensp;&ensp;&ensp;[2019-12-27](2019-12-27/daily.md)&ensp;&ensp;&ensp;&ensp;[2019-12-29](2019-12-29/daily.md)&ensp;&ensp;&ensp;&ensp;[2019-12-30](2019-12-30/daily.md)&ensp;&ensp;&ensp;&ensp;[2019-12-31](2019-12-31/daily.md)&ensp;&ensp;&ensp;&ensp;
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论