2021-09-17

SELECT 
Max(b.user_id),GROUP_CONCAT(b.`nick_name`) '姓名',AES_DECRYPT(UNHEX(a.mobile),'94e77041e7D677E524A6BBBF6B147F5A') mobilepone
FROM t_teacher_contact a
LEFT JOIN t_teacher b ON a.`user_id` = b.`user_id`
WHERE a.mobile IS NOT NULL GROUP BY mobilepone;

select name,classification from t_school where  name like '湖南%' ;


select openid,user_id,nick_name from t_app_user_bbk where openid in (3187,3110,3113,3075,3005,3212,3117,3255,105,97,3187,71,3005,109);
select openid,user_id,nick_name from t_app_user_bbk where nick_name = '';


 订单相关的表  `t_commodity`  -- 商品表
`t_commodity_association` -- 商品权益表
`t_user_purchase_commodity` -- 订单表

select t1.id,t1.user_id,pay_people,pay_price,recharge_answer_time,commodity_name,remain_fee,pay_time,teacher_service_duration,paper_explain_num,limit_time_type from t_user_purchase_commodity t1,t_app_user_bbk t2  where  t1.user_id = 3110 ;

select user_id from t_app_user_bbk where openid = 3075;

#插入兑换季卡
INSERT INTO `t_user_redeem_code` ( `redeem_code`, `redeem_time`, `start_time`, `end_time`, `redeem_status`, `create_time`, `update_time`, `user_id`, `user_name`, `account_id`, `redeem_activity_id`, `redeem_activity_name`, `remain_redeem_time`, `free_day`, `redeem_code_type`) VALUES ('wdnmd036', 10800, '2021-07-01 11:51:12', '2021-09-30 11:51:06', 0, '2021-05-19 11:49:48', '2021-09-01 11:49:48', NULL, NULL, NULL, 18, '季卡', 10800, 90, 1);
#插入优惠券
INSERT INTO `t_user_coupon` (`user_id`, `open_id`, `coupon_type`, `limit_start_time`, `limit_end_time`, `price_threshold`, `reduce_amount`, `status`, `used_time`, `create_time`, `modify_time`, `deleted`) VALUES (10625, '3332', 1, '2021-07-29 15:49:25', '2021-10-27 23:59:56', 400.00, 50.00, 1, NULL, '2021-07-29 15:49:25', NULL, 0);

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值