mysql - case, if/else statment to calculated out of spec value until within value -


i trying calculated value using case statement. know how code case statement need in coding determine how long value out of spec until came within specs. example if out of spec value = 6 , specs b = 1 c = 4. , @ point value comes within sepcs within b , c lets = 2. lets value started going out of spec @ time 00:05:00 , came within spec @ time 00:15:00. how can code using case statement know how long value out of spec until return within spec b c.

thanks in advance!

if have understood correctly:

case     when between b , c 'in specs'     else 'out of specs' end 

Comments

Popular posts from this blog

android - Get AccessToken using signpost OAuth without opening a browser (Two legged Oauth) -

org.mockito.exceptions.misusing.InvalidUseOfMatchersException: mockito -

google shop client API returns 400 bad request error while adding an item -