Changes between Version 18 and Version 19 of AdvancedReports


Ignore:
Timestamp:
12/20/22 15:02:30 (2 years ago)
Author:
191285
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • AdvancedReports

    v18 v19  
    9696  }}}
    9797}}}
     98== Број на трансакции реализирани од страна на купувачи кои оставиле позитивни рецензии (оценка над 3) кон артисти
     99
     100{{{#!div style="font-size: 90%"
     101  {{{#!sql
     102select count (*) from (
     103with tempTable as (select
     104        o.*
     105from organizers o
     106join reviews as r on
     107       r.organizer_id = o.user_id and
     108       r.rating > 3
     109group by o.user_id)
     110select
     111        t.*
     112from events as e
     113join tempTable as tt on
     114       tt.user_id = e.organizer_id
     115join offers as o2 on
     116       o2.event_id = e.id
     117join transactions as t on
     118     t.offer_id = o2.id
     119) as temp
     120  }}}
     121}}}
    98122== Настан со најмногу заинтересирани купувачи во последните 100 дена
    99123
     
    140164
    141165
    142 == Број на трансакции реализирани од страна на купувачи кои оставиле позитивни рецензии (оценка над 3) кон артисти
    143 
    144 {{{#!div style="font-size: 90%"
    145   {{{#!sql
    146 select count (*) from (
    147 with tempTable as (select
    148         o.*
    149 from organizers o
    150 join reviews as r on
    151        r.organizer_id = o.user_id and
    152        r.rating > 3
    153 group by o.user_id)
    154 select
    155         t.*
    156 from events as e
    157 join tempTable as tt on
    158        tt.user_id = e.organizer_id
    159 join offers as o2 on
    160        o2.event_id = e.id
    161 join transactions as t on
    162      t.offer_id = o2.id
    163 ) as temp
    164   }}}
    165 }}}