Skip to content

sql2 parser bug with operator precedence #12

@dbu

Description

@dbu

see phpcr/phpcr#35 for discussion

parenthesis are parsed by the sql2 parser. however, operator precedence is ignored: a or b and c gets parsed as if it was (a or b) and c. the parser should respect precedence of operators.

i suggest starting with a couple of phpcr-api-tests that test operator precendence and parenthesis (and do the assertions really based on what would be correct and not on what you get from the current implementation ;-) )

fixed
the qom to sql2 generator adds parenthesis everywhere to avoid potential problems.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions