回答編集履歴

1

調整

2023/01/10 11:39

投稿

yambejp
yambejp

スコア114885

test CHANGED
@@ -16,5 +16,10 @@
16
16
  (3,100,'2023-01-01 03:00:00');
17
17
 
18
18
  select * from tbl as t1
19
+ where not exists(
20
+ select 1 from tbl
19
- where not exists(select 1 from tbl where user_id=t1.user_id and created_at>t1.created_at);
21
+ where user_id=t1.user_id and created_at>t1.created_at
22
+ );
23
+
20
24
  ```
25
+