code: func (s *session) SetGlobalSysVar(name, value string) error {
  	if name == variable.SQLModeVar {
  		value = mysql.FormatSQLModeStr(value)
  		if _, err := mysql.GetSQLMode(value); err != nil {
  			return err
  		}
  	}
  	var sVal string
  	var err error
  	sVal, err = variable.ValidateSetSystemVar(s.sessionVars, name, value)
  	if err != nil {
  		return err
  	}
  	name = strings.ToLower(name)
  	sql := fmt.Sprintf(`REPLACE %s.%s VALUES ('%s', '%s');`,
  		mysql.SystemDB, mysql.GlobalVariablesTable, name, sVal)
  	_, _, err = s.ExecRestrictedSQL(s, sql)
  	return err
  }
docs: // SetGlobalSysVar implements GlobalVarAccessor.SetGlobalSysVar interface.