code: func (e *GrantExec) grantPriv(priv *ast.PrivElem, user *ast.UserSpec) error {
  	switch e.Level.Level {
  	case ast.GrantLevelGlobal:
  		return e.grantGlobalPriv(priv, user)
  	case ast.GrantLevelDB:
  		return e.grantDBPriv(priv, user)
  	case ast.GrantLevelTable:
  		if len(priv.Cols) == 0 {
  			return e.grantTablePriv(priv, user)
  		}
  		return e.grantColumnPriv(priv, user)
  	default:
  		return errors.Errorf("Unknown grant level: %#v", e.Level)
  	}
  }
docs: // grantPriv grants priv to user in s.Level scope.