refactor SQL EBNF