Graphs and tables for your Spotify account.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

13 lines
323 B

  1. -- select t.name as track, a.name as artist
  2. select distinct on (1)
  3. timestamp, substring(t.name for 50) as track, a.name as artist
  4. from api_history as h
  5. join api_track as t
  6. on h.track_id = t.id
  7. join api_track_artists ta
  8. on ta.track_id = t.id
  9. join api_artist a
  10. on a.id = ta.artist_id
  11. order by timestamp desc
  12. -- ;
  13. limit 20;