Refactored queryVal -> formVal