Reply To: FireStats – Top 40 php script (now with added charts)

#14786
sonichouse
Participant

@Iris wrote:

I just update summary.php and here’s the error:

Unable to execute: select 'Songs' as Item,count(1) as Desc from songs union all select 'Playlists' as Item, count(1) as Desc from playlists union all select 'Albums' as Item, count(distinct album) as Desc from songs union all select 'Albums Played' as Item, count(distinct Album) as Desc from songs where play_count>0 union all select 'Songs Played' as Item, sum(play_count) as Desc from songs where play_count>0 union all select 'Unique Songs Played' as Item, count(1) as Desc from songs where play_count>0 ;

HY000 1 near "distinct": syntax error

Iris

Hi Iris,

sqlite2 does not like the

select 'Albums Played' as Item, count(distinct Album) as Desc from songs where play_count>0

bit in that sql. I will find an approach that does work – for now can you just comment out that one sql statement ?