Skip to content

Commit d53e2a4

Browse files
committed
finish Customer Who Visited but Did Not Make Any Transactions
1 parent 5e28426 commit d53e2a4

File tree

2 files changed

+10
-0
lines changed

2 files changed

+10
-0
lines changed

SQL/SQL-50/Customer

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
select v.customer_id as customer_id, count(v.customer_id) as count_no_trans
2+
from Visits as v left join Transactions as t
3+
on v.visit_id = t.visit_id
4+
where t.visit_id is null
5+
group by v.customer_id
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
select v.customer_id as customer_id, count(v.customer_id) as count_no_trans
2+
from Visits as v left join Transactions as t
3+
on v.visit_id = t.visit_id
4+
where t.visit_id is null
5+
group by v.customer_id

0 commit comments

Comments
 (0)