chore(*.sql): use sql-formatter for sql formatting
This commit is contained in:
parent
753f3433ce
commit
a650f1d3e8
63 changed files with 4432 additions and 2358 deletions
|
@ -6,16 +6,23 @@ SELECT
|
|||
ol.artist_url,
|
||||
ARRAY_AGG(DISTINCT ol.genre_name) AS genres,
|
||||
json_build_object(
|
||||
'title', ol.artist_name,
|
||||
'image', ol.artist_art,
|
||||
'url', ol.artist_url,
|
||||
'alt', CONCAT(COUNT(*), ' plays of ', ol.artist_name),
|
||||
'subtext', CONCAT(COUNT(*), ' plays')
|
||||
'title',
|
||||
ol.artist_name,
|
||||
'image',
|
||||
ol.artist_art,
|
||||
'url',
|
||||
ol.artist_url,
|
||||
'alt',
|
||||
CONCAT(COUNT(*), ' plays of ', ol.artist_name),
|
||||
'subtext',
|
||||
CONCAT(COUNT(*), ' plays')
|
||||
) AS grid,
|
||||
json_build_object(
|
||||
'open_graph_image',
|
||||
CASE
|
||||
WHEN ol.opengraph_image_artist IS NOT NULL AND ol.opengraph_image_artist != '' AND ol.opengraph_image_artist != '/' THEN ol.opengraph_image_artist
|
||||
WHEN ol.opengraph_image_artist IS NOT NULL
|
||||
AND ol.opengraph_image_artist != ''
|
||||
AND ol.opengraph_image_artist != '/' THEN ol.opengraph_image_artist
|
||||
ELSE NULL
|
||||
END
|
||||
) AS metadata
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue