Skip to content
Advertisement

Time difference under 1h for group of records

Table looks like this

etc

I need to return play_name with column under_hour with yes for all the plays that lasted shorter than 1h ( from Start to End ).

Results should look like that:

How can i achieve that?

Advertisement

Answer

LAG function may be used with contribution of SIGN and DECODE :

demo

User contributions licensed under: CC BY-SA
5 People found this is helpful
Advertisement