grammar SQLTokens rule SPACE " " end rule SPACES SPACE+ end rule OPEN_PARENS '(' end rule CLOSE_PARENS ')' end rule EMPTY_STRING '' { def eval; nil; end } end rule TRUE "TRUE" { def eval true end } end rule FALSE "FALSE" { def eval false end } end rule SINGLE_QUOTE "'" end rule DOUBLE_QUOTE "\"" end rule BACKTICK "`" end rule COMMA "," end rule STRING_CHARS [0-9a-zA-Z\$_:] end rule ALPHA_CHARS [a-zA-Z] end rule DIGIT [0-9] end rule DASH "-" { def eval; nil; end } end rule MINUS_OR_DIGIT DASH / DIGIT end rule REAL_KEYWORD "REAL" / "real" end rule DOUBLE_KEYWORD "DOUBLE" / "double" end rule FLOAT_KEYWORD "FLOAT" / "float" end rule DECIMAL_KEYWORD "DECIMAL" / "decimal" end rule NUMERIC_KEYWORD "NUMERIC" / "numeric" end rule SMALL_INT_KEYWORD "SMALLINT" / "smallint" end rule TINY_INT_KEYWORD "TINYINT" / "tinyint" end rule INT_KEYWORD "INT" / "int" end rule INTEGER_KEYWORD "INTEGER" / "integer" end rule ZEROFILL_KEYWORD "ZEROFILL" / "zerofill" end rule UNSIGNED_KEYWORD "UNSIGNED" / "unsigned" end rule BIG_INT_KEYWORD "BIGINT" / "bigint" end rule VARCHAR_KEYWORD "VARCHAR" / "varchar" end rule DATETIME_KEYWORD "DATETIME" / "datetime" end rule NOT_KEYWORD "NOT" / "not" end rule NULL_KEYWORD "NULL" / "null" end rule NON_QUOTE_CHARS [^'"] end end