code: func builtinSleep(args []types.Datum, ctx context.Context) (d types.Datum, err error) {
  	sessVars := ctx.GetSessionVars()
  	if args[0].IsNull() {
  		if sessVars.StrictSQLMode {
  			return d, errors.New("incorrect arguments to sleep")
  		}
  		d.SetInt64(0)
  		return
  	}
  	// processing argument is negative
  	zero := types.NewIntDatum(0)
  	sc := sessVars.StmtCtx
  	ret, err := args[0].CompareDatum(sc, zero)
  	if err != nil {
  		return d, errors.Trace(err)
  	}
  	if ret == -1 {
  		if sessVars.StrictSQLMode {
  			return d, errors.New("incorrect arguments to sleep")
  		}
  		d.SetInt64(0)
  		return
  	}
  
  	// TODO: consider it's interrupted using KILL QUERY from other session, or
  	// interrupted by time out.
  	duration := time.Duration(args[0].GetFloat64() * float64(time.Second.Nanoseconds()))
  	time.Sleep(duration)
  	d.SetInt64(0)
  	return
  }
docs: // See http://dev.mysql.com/doc/refman/5.7/en/miscellaneous-functions.html#function_sleep