siva nathan

siva nathan

  • 948
  • 828
  • 232.9k

How to get column value like this in sql?

Mar 22 2017 6:34 AM
 
 intime outtime
 21-03-2017 09:01:22 21:03:2017 20:00:00
My expected output like this 
 intime OTIN OTOUT outtime
 21-03-2017 09:01:22  21-03-2017 18:01:22  21-03-2017 18:01:22  21-03-2017 20:00:00
 
 
if outtime is greater then 08pm (20:00) means OTIN time assigned as  06 pm(10:00)
same Time as OTOUT finally outtime as Outtime 

Answers (1)