drop view SessioniSecondi;

create view SessioniSecondi
as (select IdSessione, NomeUtente, AnnoNascita, to_number(to_char(timestamp,'dd'))*24*60*60+to_number(to_char(timestamp,'hh24'))*60*60+to_number(to_char(timestamp,'mi'))*60+to_number(to_char(timestamp,'ss')) as secondi
    from sessioni)