This will work:
SELECT extract(hour from tswtz)*60*60 + extract(minute from tswtz)*60 + extract(second from tswtz) s0
FROM tbl...but I thought there must be a more elegant method (such as one cast statement rather than three extracts).
↧