8 lines
293 B
SQL
8 lines
293 B
SQL
-- Determine the identifiers of purchases performed in Vienna on the last day present in the database.
|
|
|
|
SELECT Purchases.id AS ids
|
|
FROM Purchases
|
|
JOIN province ON province.ROWID = Purchases.province
|
|
WHERE time > date((SELECT MAX(time) FROM Purchases),'-1 days') AND province.name = 'Vienna'
|
|
;
|