Commit 91f4294b authored by Sergio Bruni's avatar Sergio Bruni
Browse files

aa

parent 232b7341
......@@ -563,9 +563,16 @@ GROUP BY s.id
#### come sopra con evidenza del numero di rinex ripetuti per stazione
select s.marker, max(numero_casi_molteplici) as numero_casi_molteplici, max(molteplicita_massima) as molteplicita_massima, count(*) numero_reti, string_agg(n.name, ', ') from (
select a.id_station, count(*) as numero_casi_molteplici, max(numero_rinex_multipli) as molteplicita_massima from (
select id_station, count(*) as numero_rinex_multipli from rinex_file r
select s.marker, max(numero_casi_molteplici) as numero_casi_molteplici,
max(molteplicita_massima) as molteplicita_massima,
count(*) numero_reti,
string_agg(n.name, ', ') reti,
string_agg(cast(n.id as text), ', ') id_reti from (
select a.id_station,
count(*) as numero_casi_molteplici,
max(numero_rinex_multipli) as molteplicita_massima from (
select id_station, count(*) as numero_rinex_multipli
from rinex_file r
group by id_station, r.reference_date
having count(*) > 1
) a
......@@ -575,7 +582,7 @@ GROUP BY s.id
JOIN station_network sn ON sn.id_station=s.id
JOIN network n ON n.id=sn.id_network
group by s.marker
order by max(numero_casi_molteplici)
order by numero_reti, max(numero_casi_molteplici)
-- order by numero_reti
-- order by marker
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment