GuaMiao
GuaMiao
全部文章
分类
归档
标签
去牛客网
登录
/
注册
GuaMiao的博客
全部文章
(共92篇)
题解 | #牛客的课程订单分析(三)#
select * from order_info where user_id in ( select user_id from order_info where date > '2025-10-15' and product_name in ('Python',...
2023-09-10
0
315
题解 | #异常的邮件概率#简单题
# 先查找出正常用户的id with t1 as ( select id from user where is_blacklist = 0 ) # 找到正常用户发送给正常用户的邮件记录 select date, ROUND(sum(type='no_completed')/c...
2023-09-08
0
402
简单题,考察连接以及分组
select a.title, AVG(b.salary) as 'avg(s.salary)' from titles as a left join salaries as b on a.emp_no = b.emp_no group by a.title order by 'avg(s.sala...
2023-09-04
0
378
题解 | #实习广场投递简历分析(二)#
select job, DATE_FORMAT(date, '%Y-%m') as mon, SUM(num) as cnt from resume_info where date between '2025-01-01' and '2025-12-31' group by job, mon or...
2023-09-04
0
284
题解 | #统计各个部门的工资记录数#
select d.dept_no, c.dept_name, count(d.emp_no) as sum from ( select b.dept_no, a.emp_no from salaries as a left join dept_emp as b on ...
2023-09-02
0
272
题解 | #牛客的课程订单分析(六)#
# 先找到满足条件的记录 select a.id, a.is_group_buy, b.name from ( select id, user_id, client_id, is_group_buy from order_info where user_id in ( ...
2023-09-02
0
342
题解 | #今天的刷题量(一)#
with t1 as ( select b.name, a.subject_id, create_time from submission as a left join subject as b on a.subject_id = b.id ) select name...
2023-09-02
0
345
题解 | 获取员工其当前的薪水比其manager当前薪水还高
# 先找到每个员工当前薪水 with t1 as ( select a.emp_no, a.dept_no, b.salary from dept_emp as a left join salaries as b on a.emp_no = b.emp_no ...
2023-09-02
0
431
题解 | #牛客的课程订单分析(五)#
# 先找到满足条件得记录 with t1 as ( select user_id, date from order_info where date > '2025-10-15' and status = 'completed' and product_...
2023-09-01
1
259
题解 | RIGHT提取右边指定长度字符串
select first_name from ( select first_name, RIGHT(first_name, 2) as last_two_string from employees order by last_two_string ) as a;
2023-08-31
0
408
首页
上一页
1
2
3
4
5
6
7
8
9
10
下一页
末页