mysql exe

没事刷到了,上午刷都刷了,整理一下吧

lc1873

Write your MySQL query statement below

SELECT

employee_id,

CASE

WHEN employee_id % 2 = 1 AND name NOT LIKE 'M%' THEN salary

ELSE 0

END AS bonus

FROM Employees

ORDER BY employee_id;

lc619

Write your MySQL query statement below

SELECT

MAX(num) AS num

FROM (

SELECT num

FROM MyNumbers

GROUP BY num

HAVING COUNT(*) = 1

) AS single_numbers;

lc1148

Write your MySQL query statement below

select

author_id as 'id'

from

Views

where

Views.author_id = Views.viewer_id

group by

author_id

order by

author_id

lc183

Write your MySQL query statement below

select Customers.name as 'Customers'

from Customers

where Customers.id not in (

select Orders.customerId

from Orders

)

lc196

Write your MySQL query statement below

DELETE p1 #只删除表p1

FROM Person AS p1

INNER JOIN Person AS p2

WHERE p1.Email = p2.Email

AND p1.Id > p2.Id

相关推荐
淡海水7 小时前
07-04-并发-ConcurrentBag-T-工作窃取WorkStealing算法
开发语言·算法·c#·bag·concurrent·workstealing
leobertlan7 小时前
好玩系列:训练一个神经网络模型指导小孩玩游戏2-大局观教练
算法
Tisfy8 小时前
LeetCode 3876.构造奇偶一致的数组 II:三种情况分类讨论(其实还是脑筋急转弯)
算法·leetcode·题解·脑筋急转弯
乐迪信息9 小时前
智慧港口船舶AI算法实现在线状态监测
大数据·人工智能·深度学习·算法·计算机视觉
木井巳11 小时前
【BFS/DFS 解决 FloodFill 算法】太平洋大西洋水流问题
java·算法·leetcode·深度优先·广度优先·宽度优先·推荐算法
心抵鹊11 小时前
归并排序之翻转对(hard)
数据结构·算法
白山编程大哥11 小时前
Java 集合算法:从排序、查找到底层原理的实战指南
java·python·算法
shehuiyuelaiyuehao11 小时前
算法34,位运算符操作,总结
算法
Navigator_Z11 小时前
LeetCode //C - 1224. Maximum Equal Frequency
c语言·算法·leetcode
Navigator_Z12 小时前
LeetCode //C++ - 1226. The Dining Philosophers
c语言·算法·leetcode