1809. Ad-Free Sessions
https://leetcode.com/problems/ad-free-sessions
Description
Table: Playback
+-------------+------+
| Column Name | Type |
+-------------+------+
| session\_id | int |
| customer\_id | int |
| start\_time | int |
| end\_time | int |
+-------------+------+
session\_id is the primary key for this table.
customer\_id is the ID of the customer watching this session.
The session runs during the **inclusive** interval between start\_time and end\_time.
It is guaranteed that start\_time <= end\_time and that two sessions for the same customer do not intersect.Table: Ads
+-------------+------+
| Column Name | Type |
+-------------+------+
| ad\_id | int |
| customer\_id | int |
| timestamp | int |
+-------------+------+
ad\_id is the primary key for this table.
customer\_id is the ID of the customer viewing this ad.
timestamp is the moment of time at which the ad was shown.Write an SQL query to report all the sessions that did not get shown any ads.
Return the result table in any order.
The query result format is in the following example:
ac
Last updated
Was this helpful?