mirror of
https://github.com/twitter/the-algorithm.git
synced 2024-12-23 01:55:37 +00:00
ef4c5eb65e
Please note we have force-pushed a new initial commit in order to remove some publicly-available Twitter user information. Note that this process may be required in the future.
6 lines
409 B
SQL
6 lines
409 B
SQL
WITH maxts as (SELECT as value MAX(ts) as ts FROM `twttr-recos-ml-prod.ssedhain.twhin_tweet_avg_embedding`)
|
|
SELECT entityId, embedding
|
|
FROM `twttr-recos-ml-prod.ssedhain.twhin_tweet_avg_embedding`
|
|
WHERE ts >= (select max(maxts) from maxts)
|
|
AND DATE(TIMESTAMP_MILLIS(createdAt)) <= (select max(maxts) from maxts)
|
|
AND DATE(TIMESTAMP_MILLIS(createdAt)) >= DATE_SUB((select max(maxts) from maxts), INTERVAL 1 DAY) |